FUML 1.1 RTF Avatar
  1. OMG Issue

FUML11 — Bug in ForkedToken::withdraw when the baseToken is a ForkedToken

  • Key: FUML11-13
  • Legacy Issue Number: 17203
  • Status: closed  
  • Source: Model Driven Solutions ( Mr. Ed Seidewitz)
  • Summary:

    Specification: Semantics of a Foundational Subset for Executable UML Models (fUML) (formal/2011-02-01)

    Subclause: 8.5.2.2.10 ForkedToken

    ForkedToken::withdraw calls isWithdrawn() to check if its baseToken is withdrawn, and then withdraws it if that is false. The intent is that baseToken.withdraw() only be called once. However, if the baseToken is itself a ForkedToken, then calling withdraw() may only decrement the remainingOffersCount of that token, with isWithdrawn() only becoming true if this count goes to zero. This means that additional calls to withdraw() on the first ForkedToken may result in additional calls to withdraw() on its baseToken, prematurely reducing the remainingOffersCount for the baseToken.

    This can be avoided by adding an explicit baseTokenIsWithdrawn flag to ForkedToken that is set when the baseToken is withdrawn and then checked to avoid further withdraws.

  • Reported: FUML 1.0 — Tue, 28 Feb 2012 05:00 GMT
  • Disposition: Resolved — FUML 1.1
  • Disposition Summary:

    agreed

  • Updated: Fri, 6 Mar 2015 20:58 GMT