From 1f57fe3de42b9a96557b7a4acbf1deb9adb93d6d Mon Sep 17 00:00:00 2001 From: watney Date: Wed, 22 May 2024 17:31:16 -0700 Subject: [PATCH 01/10] Just grab the docs changes --- docs/code-prettify/run_prettify.js | 14 +- docs/fpp-spec.html | 1799 ++++++++++++----- docs/fpp-users-guide.html | 177 +- docs/index.html | 167 +- .../Definitions/Component-Definitions.adoc | 35 + docs/spec/Definitions/Module-Definitions.adoc | 3 + .../State-Machine-Definitions.adoc | 90 + docs/spec/Definitions/defs.sh | 1 + docs/spec/Device.fpp | 98 + docs/spec/Device.plantuml | 54 + docs/spec/Device.png | Bin 0 -> 43308 bytes docs/spec/Lexical-Elements.adoc | 12 + .../State-Machine-Instance-Specifiers.adoc | 30 + docs/spec/Specifiers/defs.sh | 1 + .../State-Machine-Behavior/Introduction.adoc | 2 + .../State-Machine-Behavior/State-Actions.adoc | 34 + .../State-Definition.adoc | 85 + .../State-Machine-Behavior/State-Events.adoc | 34 + .../State-Machine-Behavior/State-Guards.adoc | 34 + .../State-Machine-Behavior/State-Initial.adoc | 43 + .../State-Junction.adoc | 51 + .../State-Machine-Behavior.adoc | 403 ++++ .../State-Machine-Behavior.adoc.do | 15 + .../State-Transition.adoc | 68 + .../State-Machine-Behavior/State-Visit.adoc | 43 + docs/spec/State-Machine-Behavior/all.do | 7 + docs/spec/State-Machine-Behavior/clean.do | 7 + docs/spec/State-Machine-Behavior/defs.sh | 19 + docs/spec/defs.sh | 1 + docs/spec/test.fpp | 20 + docs/users-guide/Defining-Components.adoc | 4 +- editors/emacs/fpp-mode.el | 2 +- editors/vim/fpp.vim | 2 + 33 files changed, 2696 insertions(+), 659 deletions(-) create mode 100644 docs/spec/Definitions/State-Machine-Definitions.adoc create mode 100644 docs/spec/Device.fpp create mode 100644 docs/spec/Device.plantuml create mode 100644 docs/spec/Device.png create mode 100644 docs/spec/Specifiers/State-Machine-Instance-Specifiers.adoc create mode 100644 docs/spec/State-Machine-Behavior/Introduction.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Actions.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Definition.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Events.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Guards.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Initial.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Junction.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Machine-Behavior.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Machine-Behavior.adoc.do create mode 100644 docs/spec/State-Machine-Behavior/State-Transition.adoc create mode 100644 docs/spec/State-Machine-Behavior/State-Visit.adoc create mode 100644 docs/spec/State-Machine-Behavior/all.do create mode 100644 docs/spec/State-Machine-Behavior/clean.do create mode 100644 docs/spec/State-Machine-Behavior/defs.sh create mode 100644 docs/spec/test.fpp diff --git a/docs/code-prettify/run_prettify.js b/docs/code-prettify/run_prettify.js index 9c37a6d4e..41af03706 100644 --- a/docs/code-prettify/run_prettify.js +++ b/docs/code-prettify/run_prettify.js @@ -404,8 +404,9 @@ var IN_GLOBAL_SCOPE = false; // We use things that coerce to strings to make them compact when minified // and to defeat aggressive optimizers that fold large string constants. var FPP_KEYWORDS = [ - "active," + - "activity," + + "action," + + "active," + + "activity," + "always," + "array," + "assert," + @@ -423,23 +424,30 @@ var IN_GLOBAL_SCOPE = false; "cpu," + "default," + "diagnostic," + + "do," + "drop," + + "else," + "enum," + "event," + "fatal," + "format," + "get," + + "guard," + "guarded," + "health," + "high," + "id," + + "if," + "import," + "include," + + "initial," + "input," + "instance," + "internal," + + "junction," + "locate," + "low," + + "machine," + "match," + "module," + "on," + @@ -469,6 +477,7 @@ var IN_GLOBAL_SCOPE = false; "severity," + "size," + "stack," + + "state," + "string," + "struct," + "sync," + @@ -479,6 +488,7 @@ var IN_GLOBAL_SCOPE = false; "topology," + "type," + "update," + + "visit," + "warning," + "with," + "yellow" diff --git a/docs/fpp-spec.html b/docs/fpp-spec.html index b1a4d45f4..7bebe37e4 100644 --- a/docs/fpp-spec.html +++ b/docs/fpp-spec.html @@ -4,23 +4,25 @@ - + The F Prime Prime (FPP) Language Specification, Unreleased, after v2.0.2 - +
+
+
@ A component that has a state machine
+active component DeviceMgr {
+
+  # ----------------------------------------------------------------------
+  # State machines
+  # ----------------------------------------------------------------------
+
+  @ A state machine definition
+  state machine DeviceSM {
+
+    event StartCmd
+    event OffCmd
+
+    initial IDLE
+
+    state IDLE {
+      on StartCmd visit RUNNING
+    }
+
+    state RUNNING {
+      on OffCmd visit IDLE
+    }
+
+  }
+
+  @ state machine instance 1
+  state machine instance device1Machine: DeviceSM
+
+  @ state machine instance 2
+  state machine instance device2Machine: DeviceSM
+}
+
+
@@ -2460,6 +2583,9 @@

5.8.1. Syntax

  • An include specifier

  • +
  • +

    A state machine definition

    +
  • @@ -2568,13 +2694,137 @@

    5.9.3. Examples

    -

    5.10. Struct Definitions

    +

    5.10. State Machine Definitions

    +
    +

    A state machine definion defines a state machine

    +
    +
    +

    5.10.1. Syntax

    +
    +
      +
    • +

      state machine identifier +{ state-machine-behavior }

      +
    • +
    +
    +
    +

    state-machine-behavior is an +element sequence in +which each element is a state machine member, +and the terminating punctuation is a semicolon. +A state machine member is one of the following

    +
    +
    + +
    +
    +
    +

    5.10.2. Semantics

    +
    +
      +
    1. +

      The identifier specifies the name of the state machine.

      +
    2. +
    3. +

      The state-machine-behavior describes +a hierarchical state machine.

      +
    4. +
    5. +

      state_events specify all the events that can be dispatched to this state machine. An event causes a state transition

      +
    6. +
    7. +

      state actions specify all the actions that can be invoked by this state machine. An action is a function that’s called on a state transition

      +
    8. +
    9. +

      state guards specify all the guards that are used in transitions by this state machine. A guard is a predicate that indicates if a transition can occur

      +
    10. +
    11. +

      The state machine must have one state initial that specifies the initial state

      +
    12. +
    +
    +
    +
    +

    5.10.3. Examples

    +
    +
    +
    state machine MonitorSm {
    +
    +    event Complete
    +    event Drive
    +    event Calibrate
    +    event RTI
    +    event Stop
    +    event Fault
    +
    +    action init2
    +    action doCalibrate
    +    action motorControl
    +    action reportFault
    +
    +    guard calibrateReady
    +
    +    initial DeviceOn
    +
    +    state DeviceOn {
    +
    +        initial Initializing do init2
    +
    +        state Initializing {
    +            on Complete visit Idle
    +        }
    +
    +        state Idle {
    +            on Drive visit Driving
    +            on Calibrate if calibrateReady visit Calibrating
    +        }
    +
    +        state Calibrating {
    +            on RTI do doCalibrate
    +            on Fault go Idle do reportFault
    +            on Complete visit Idle
    +        }
    +
    +        state Driving {
    +            on RTI do motorControl
    +            on Stop visit Idle
    +        }
    +
    +    }
    +
    +}
    +
    +
    +
    +
    +
    +

    5.11. Struct Definitions

    A struct definition defines a new structure type and associates a name with it.

    -

    5.10.1. Syntax

    +

    5.11.1. Syntax

    struct identifier { struct-type-member-sequence } @@ -2598,7 +2848,7 @@

    5.10.1. Syntax

    -

    5.10.2. Semantics

    +

    5.11.2. Semantics

    The identifier is the name N of the type. The definition associates the name N with a @@ -2636,7 +2886,7 @@

    5.10.2. Semantics

    -

    5.10.3. Examples

    +

    5.11.3. Examples

    # Defines a struct type A with members x and y
    @@ -2671,7 +2921,7 @@ 

    5.10.3. Examples

    -

    5.11. Topology Definitions

    +

    5.12. Topology Definitions

    A topology definition defines an F Prime topology, that is, a set of component instances and the connections @@ -2685,7 +2935,7 @@

    5.11. Topology Definitions

    The connections are merged graph by graph.

    -

    5.11.1. Syntax

    +

    5.12.1. Syntax

    topology identifier @@ -2717,7 +2967,7 @@

    5.11.1. Syntax

    -

    5.11.2. Semantics

    +

    5.12.2. Semantics

    A topology definition D must be resolvable to a topology T, according to the following algorithm:

    @@ -3024,7 +3274,7 @@
    Orde
    -

    5.11.3. Examples

    +

    5.12.3. Examples

    Example 1.

    @@ -3223,7 +3473,544 @@

    5.11.3. Examples

    -

    6. Specifiers

    +

    6. State Machine Behavior

    +
    +
    +

    6.1. State Events

    +
    +

    state events specifies events that are dispatched to the state machine which causes the state machine to run to completion. +When a state machine runs to completion it means that it processes all pending events and transitions through its states until it reaches a stable state where no further transitions are immediately required.

    +
    +
    +

    6.1.1. Syntax

    +
    +

    event +identifier +[ +: +type-name +]

    +
    +
    +
    +

    6.1.2. Semantics

    +
    +
      +
    1. +

      The identifier specifies the event name.

      +
    2. +
    3. +

      If present, the optional type-name names the type of the data carried by the event. If type-name is not present, then the event carries no data

      +
    4. +
    +
    +
    +
    +

    6.1.3. Examples

    +
    +
    +
    struct FaultData {
    +    id: U32
    +    data: U32
    +}
    +
    +# An event without data
    +event RTI
    +
    +# An event with data
    +event Fault: FaultData
    +
    +
    +
    +
    +
    +

    6.2. State Actions

    +
    +

    state actions specifies actions that are invoked upon transitions. Actions are functions that can carry data.

    +
    +
    +

    6.2.1. Syntax

    +
    +

    action +identifier +[ +: +type-name +]

    +
    +
    +
    +

    6.2.2. Semantics

    +
    +
      +
    1. +

      The identifier specifies the action name.

      +
    2. +
    3. +

      The type-name specifies an optional data type associated with the action and will be +passed into the action function when invoked.

      +
    4. +
    +
    +
    +
    +

    6.2.3. Examples

    +
    +
    +
    struct FaultData {
    +    id: U32
    +    data: U32
    +}
    +
    +# An action without data
    +action initPower
    +
    +# An action with data
    +action reportFault: FaultData
    +
    +
    +
    +
    +
    +

    6.3. State Guards

    +
    +

    state guards specifies guards that are associated with transitions. A guard is a predicate or function that returns a boolean. Guards are placed on transitions. When a guard evaluates to True the transition is taken, else the transition is not taken.

    +
    +
    +

    6.3.1. Syntax

    +
    +

    guard +identifier +[ +: +type-name +]

    +
    +
    +
    +

    6.3.2. Semantics

    +
    +
      +
    1. +

      The identifier specifies the guard name wich is a function that returns a boolean. When the guard is evaluated to True, it allows the transition to be invoked.

      +
    2. +
    3. +

      The type-name specifies an optional data type associated with the guard and will be +passed into the guard function when invoked.

      +
    4. +
    +
    +
    +
    +

    6.3.3. Examples

    +
    +
    +
    struct FaultData {
    +    id: U32
    +    data: U32
    +}
    +
    +# A guard without data
    +guard noRecovery
    +
    +# A guard with data
    +guard noRecovery: FaultData
    +
    +
    +
    +
    +
    +

    6.4. State Definition

    +
    +

    A state definition specifies a state in a +state machine

    +
    +
    +

    6.4.1. Syntax

    +
    +

    state identifier +[ { state_sequence } ]

    +
    +
    +

    state-sequence is an +element sequence in +which each element is a state member, +and the terminating punctuation is a semicolon. +A state member is one of the following

    +
    + +
    +
    +

    6.4.2. Semantics

    +
    +
      +
    1. +

      The identifier specifies the name of a state in the state machine

      +
    2. +
    3. +

      The state can be hierarchical, a state can be defined within another state

      +
    4. +
    5. +

      The state is required to have one initial specification if it is a hierarchical state

      +
    6. +
    7. +

      The state can have junctions

      +
    8. +
    9. +

      All transitions that originate from a state are required to be specified inside that state

      +
    10. +
    +
    +
    +
    +

    6.4.3. Examples

    +
    +
    +
    state machine MonitorSm {
    +
    +    event Complete
    +    event Drive
    +    event Calibrate
    +    event RTI
    +    event Stop
    +    event Fault
    +
    +    action init2
    +    action doCalibrate
    +    action motorControl
    +    action reportFault
    +
    +    guard calibrateReady
    +
    +    initial DEVICE_ON
    +
    +    state DEVICE_ON {
    +
    +        initial INITIALIZING do init2
    +
    +        state INITIALIZING {
    +            on Complete visit IDLE
    +        }
    +
    +        state IDLE {
    +            on Drive visit DRIVING
    +            on Calibrate if calibrateReady visit CALIBRATING
    +        }
    +
    +        state CALIBRATING {
    +            on RTI do doCalibrate
    +            on Fault go Idle do reportFault
    +            on Complete visit IDLE
    +        }
    +
    +        state DRIVING {
    +            on RTI do motorControl
    +            on Stop visit IDLE
    +        }
    +
    +    }
    +
    +}
    +
    +
    +
    +
    +
    +

    6.5. State Initial

    +
    +

    A state initial specifies an initial state transition

    +
    +
    +

    6.5.1. Syntax

    +
    +

    initial +qual-ident +[ +do +identifier +]

    +
    +
    +
    +

    6.5.2. Semantics

    +
    +
      +
    1. +

      The qual-ident specifies the state or junction that will be visited when the state machine starts running.

      +
    2. +
    3. +

      An initial specification is required at the top of the state machine

      +
    4. +
    5. +

      An initial specification is required at the top of every hierarchical state

      +
    6. +
    7. +

      The optional identifier after the keyword do specifies the action performed before visiting the initial state

      +
    8. +
    +
    +
    +
    +

    6.5.3. Examples

    +
    +
    +
    state machine Device {
    +
    +    action initDevices
    +
    +    initial ON
    +
    +    state ON {
    +
    +        initial POWERING_UP do initDevices
    +
    +        state POWERING_UP {
    +
    +        }
    +    }
    +
    +
    +
    +
    +
    +

    6.6. State Junction

    +
    +

    A state junction specifies a state junction in a +state machine. +A junction is a type of psuedo state. It serves as an intermediate point in a transition path allowing a transtion to branch based on the returned value of the guard (predicate). Other psuedo states in the state machine terminology are initial and final

    +
    +
    +

    6.6.1. Syntax

    +
    +

    junction identifier +{ +if identifier state visit +else state visit +}

    +
    +
    +
    +

    6.6.2. Semantics

    +
    +
      +
    1. +

      The identifier after the keyword junction is the name of the junction.

      +
    2. +
    3. +

      Each junction requires a unique name.

      +
    4. +
    5. +

      The identifier after the keyword if specifies the name of the guard

      +
    6. +
    7. +

      The state visit specifies the state to enter with an optional action

      +
    8. +
    +
    +
    +
    +

    6.6.3. Examples

    +
    +
    +
    state machine Device {
    +
    +    action initPower
    +    guard coldStart
    +
    +    initial J1
    +
    +    junction J1 {
    +            if coldStart visit OFF
    +            else visit ON do initPower
    +    }
    +
    +    state OFF {
    +
    +    }
    +
    +    state ON {
    +
    +    }
    +
    +}
    +
    +
    +
    +
    +
    +

    6.7. State Transition

    +
    +

    A state transition specifies a state transition in a +state machine

    +
    +
    +

    6.7.1. Syntax

    +
    +

    A state transition is one of the following:

    +
    +
    +
      +
    • +

      regular_transtion

      +
    • +
    • +

      self_transition

      +
    • +
    +
    +
    +

    regular_transition has the following syntax:

    +
    +
    + +
    +
    +

    self_transition has the following syntax:

    +
    +
    + +
    +
    +
    +

    6.7.2. Semantics

    +
    +
      +
    1. +

      The identifier after the keyword on is the name of the event that triggers this transition

      +
    2. +
    3. +

      The optional identifier after the keyword if is the name of the guard for this transition

      +
    4. +
    5. +

      The identifier after the keyword do is the action performed

      +
    6. +
    7. +

      The state visit specifies the name of the target state and the optional action performed

      +
    8. +
    +
    +
    +
    +

    6.7.3. Examples

    +
    +
    +
    state machine Device {
    +
    +    event RTI
    +    event PowerOn
    +
    +    action performStuff
    +    action getReady
    +
    +    guard initComplete
    +
    +    initial OFF
    +
    +    state OFF
    +        on PowerOn if initComplete visit ON do getReady
    +
    +    }
    +
    +    state ON {
    +        on RTI do performStuff
    +
    +    }
    +
    +}
    +
    +
    +
    +
    +
    +

    6.8. State Visit

    +
    +

    A state visit specifies a visit or entry into another state with optional actions

    +
    +
    +

    6.8.1. Syntax

    +
    +

    visit qual-ident +[ +do identifier +]

    +
    +
    +
    +

    6.8.2. Semantics

    +
    +
      +
    1. +

      The qual-ident after the keyword visit is the state which is visited or entered

      +
    2. +
    3. +

      The optional identifier after the keyword do specifies the action performed when the transition is taken

      +
    4. +
    +
    +
    +
    +

    6.8.3. Examples

    +
    +
    +
    state machine Device {
    +
    +    event PowerOn
    +
    +    action getReady
    +
    +    guard initComplete
    +
    +    initial OFF
    +
    +    state OFF {
    +        on PowerOn if initComplete visit ON do getReady
    +
    +    }
    +
    +    state ON {
    +
    +    }
    +
    +}
    +
    +
    +
    +
    +
    +
    +
    +

    7. Specifiers

    A specifier is a unit of syntax that specifies some information @@ -3234,13 +4021,13 @@

    6. Specifiers

    globally unique qualified name.

    -

    6.1. Command Specifiers

    +

    7.1. Command Specifiers

    A command specifier specifies a command as part of a component definition.

    -

    6.1.1. Syntax

    +

    7.1.1. Syntax

    command-kind command identifier [ @@ -3278,7 +4065,7 @@

    6.1.1. Syntax

    -

    6.1.2. Semantics

    +

    7.1.2. Semantics

    • @@ -3320,7 +4107,7 @@

      6.1.2. Semantics

    -

    6.1.3. Examples

    +

    7.1.3. Examples

    @ A sync command with no parameters
    @@ -3357,7 +4144,7 @@ 

    6.1.3. Examples

    -

    6.2. Component Instance Specifiers

    +

    7.2. Component Instance Specifiers

    A component instance specifier specifies that a @@ -3366,7 +4153,7 @@

    6.2. Component Instance Specif topology.

    -

    6.2.1. Syntax

    +

    7.2.1. Syntax

    [ private ] instance @@ -3374,7 +4161,7 @@

    6.2.1. Syntax

    -

    6.2.2. Semantics

    +

    7.2.2. Semantics

    • @@ -3403,7 +4190,7 @@

      6.2.2. Semantics

    -

    6.2.3. Example

    +

    7.2.3. Example

    component A { ... }
    @@ -3437,7 +4224,7 @@ 

    6.2.3. Example

    -

    6.3. Connection Graph Specifiers

    +

    7.3. Connection Graph Specifiers

    A connection graph specifier specifies one or more connection graphs as part of a @@ -3451,7 +4238,7 @@

    6.3. Connection Graph Specifiers another.

    -

    6.3.1. Syntax

    +

    7.3.1. Syntax

    A connection graph specifier is one of the following:

    @@ -3530,7 +4317,7 @@

    6.3.1. Syntax

    -

    6.3.2. Semantics

    +

    7.3.2. Semantics

    Direct graph specifiers. A direct graph specifier directly specifies a named connection graph.

    @@ -3707,7 +4494,7 @@

    6.3.2. Semantics

    -

    6.3.3. Example

    +

    7.3.3. Example

    Assume the following instances are available in the enclosing topology, and all have command ports:

    @@ -3770,7 +4557,7 @@

    6.3.3. Example

    -

    6.4. Container Specifiers

    +

    7.4. Container Specifiers

    A container specifier specifies a data product container as part of a component definition. @@ -3778,7 +4565,7 @@

    6.4. Container Specifiers

    They hold data product records.

    -

    6.4.1. Syntax

    +

    7.4.1. Syntax

    product container identifier [ @@ -3790,7 +4577,7 @@

    6.4.1. Syntax

    -

    6.4.2. Semantics

    +

    7.4.2. Semantics

    1. @@ -3820,7 +4607,7 @@

      6.4.2. Semantics

    -

    6.4.3. Examples

    +

    7.4.3. Examples

    @ Container 0
    @@ -3838,13 +4625,13 @@ 

    6.4.3. Examples

    -

    6.5. Event Specifiers

    +

    7.5. Event Specifiers

    An event specifier specifies an event report as part of a component definition.

    -

    6.5.1. Syntax

    +

    7.5.1. Syntax

    event identifier @@ -3890,7 +4677,7 @@

    6.5.1. Syntax

    -

    6.5.2. Semantics

    +

    7.5.2. Semantics

    • @@ -3932,7 +4719,7 @@

      6.5.2. Semantics

    -

    6.5.3. Examples

    +

    7.5.3. Examples

    @ An array of 3 F64 values
    @@ -3971,20 +4758,20 @@ 

    6.5.3. Examples

    -

    6.6. Include Specifiers

    +

    7.6. Include Specifiers

    An include specifier specifies that a file should be included in a translation unit.

    -

    6.6.1. Syntax

    +

    7.6.1. Syntax

    include string-literal

    -

    6.6.2. Semantics

    +

    7.6.2. Semantics

    The string literal specifies a file path relative to the location of the include specifier.

    @@ -4013,7 +4800,7 @@

    6.6.2. Semantics

    -

    6.6.3. Examples

    +

    7.6.3. Examples

    Example 1.

    @@ -4075,7 +4862,7 @@

    6.6.3. Examples

    -

    6.7. Init Specifiers

    +

    7.7. Init Specifiers

    An init specifier associates some code with a component instance. @@ -4083,14 +4870,14 @@

    6.7. Init Specifiers

    It may also serve another purpose (e.g., teardown).

    -

    6.7.1. Syntax

    +

    7.7.1. Syntax

    -

    6.7.2. Semantics

    +

    7.7.2. Semantics

    • @@ -4114,7 +4901,7 @@

      6.7.2. Semantics

    -

    6.7.3. Example

    +

    7.7.3. Example

    @ Phases of initialization
    @@ -4174,7 +4961,7 @@ 

    6.7.3. Example

    -

    6.8. Internal Port Specifiers

    +

    7.8. Internal Port Specifiers

    An internal port specifier specifies a single-use port for use in handlers of the enclosing @@ -4183,7 +4970,7 @@

    6.8. Internal Port Specifiers

    to itself.

    -

    6.8.1. Syntax

    +

    7.8.1. Syntax

    internal port identifier @@ -4205,7 +4992,7 @@

    6.8.1. Syntax

    -

    6.8.2. Semantics

    +

    7.8.2. Semantics

    The identifier is the name of the port. The parameter list specifies the formal parameters of the @@ -4220,7 +5007,7 @@

    6.8.2. Semantics

    -

    6.8.3. Examples

    +

    7.8.3. Examples

    @ Port 1
    @@ -4239,14 +5026,14 @@ 

    6.8.3. Examples

    -

    6.9. Location Specifiers

    +

    7.9. Location Specifiers

    A location specifier specifies the location of a definition.

    -

    6.9.1. Syntax

    +

    7.9.1. Syntax

    A location specifier is one of the following:

    @@ -4286,7 +5073,7 @@

    6.9.1. Syntax

    -

    6.9.2. Semantics

    +

    7.9.2. Semantics

    1. @@ -4357,7 +5144,7 @@

      6.9.2. Semantics

    -

    6.9.3. Examples

    +

    7.9.3. Examples

    Example 1:

    @@ -4410,13 +5197,13 @@

    6.9.3. Examples

    -

    6.10. Parameter Specifiers

    +

    7.10. Parameter Specifiers

    A parameter specifier specifies a parameter as part of a component definition.

    -

    6.10.1. Syntax

    +

    7.10.1. Syntax

    param identifier : type-name @@ -4435,7 +5222,7 @@

    6.10.1. Syntax

    -

    6.10.2. Semantics

    +

    7.10.2. Semantics

    • @@ -4490,7 +5277,7 @@

      6.10.2. Semantics

    -

    6.10.3. Examples

    +

    7.10.3. Examples

    @ Parameter 1
    @@ -4510,7 +5297,7 @@ 

    6.10.3. Examples

    -

    6.11. Port Instance Specifiers

    +

    7.11. Port Instance Specifiers

    A port instance specifier specifies an instantiated port as part @@ -4518,7 +5305,7 @@

    6.11. Port Instance Specifiers

    component definition.

    -

    6.11.1. Syntax

    +

    7.11.1. Syntax

    A port instance specifier is one of the following:

    @@ -4677,7 +5464,7 @@

    6.11.1. Syntax

    -

    6.11.2. Semantics

    +

    7.11.2. Semantics

    General port instances:

    @@ -4853,7 +5640,7 @@

    6.11.2. Semantics

    -

    6.11.3. Examples

    +

    7.11.3. Examples

    General ports:

    @@ -4922,7 +5709,7 @@

    6.11.3. Examples

    -

    6.12. Port Matching Specifiers

    +

    7.12. Port Matching Specifiers

    A port matching specifier is part of a component definition. @@ -4935,7 +5722,7 @@

    6.12. Port Matching Specifiers

    to its ping input port at the same port number n.

    -

    6.12.1. Syntax

    +

    7.12.1. Syntax

    match identifier @@ -4944,7 +5731,7 @@

    6.12.1. Syntax

    -

    6.12.2. Semantics

    +

    7.12.2. Semantics

    1. @@ -4960,7 +5747,7 @@

      6.12.2. Semantics

    -

    6.12.3. Example

    +

    7.12.3. Example

    queued component Health {
    @@ -4983,7 +5770,7 @@ 

    6.12.3. Example

    -

    6.13. Record Specifiers

    +

    7.13. Record Specifiers

    A record specifier specifies a data product record as part of a component definition. @@ -4991,7 +5778,7 @@

    6.13. Record Specifiers

    container.

    -

    6.13.1. Syntax

    +

    7.13.1. Syntax

    product record identifier : type-name @@ -5004,7 +5791,7 @@

    6.13.1. Syntax

    -

    6.13.2. Semantics

    +

    7.13.2. Semantics

    1. @@ -5042,7 +5829,7 @@

      6.13.2. Semantics

    -

    6.13.3. Examples

    +

    7.13.3. Examples

    @ An array of 3 F64 values
    @@ -5063,13 +5850,54 @@ 

    6.13.3. Examples

    -

    6.14. Telemetry Channel Specifiers

    +

    7.14. State Machine Instance Specifiers

    +
    +

    A state machine instance specifier instantiates a state machine definition.

    +
    +
    +

    7.14.1. Syntax

    +
    +

    state machine instance +identifier +: +qual-ident

    +
    +
    +
    +

    7.14.2. Semantics

    +
    +
      +
    1. +

      The identifier is the name of the instantiated state machine

      +
    2. +
    3. +

      The qual-ident is the name of the state machine definition

      +
    4. +
    +
    +
    +
    +

    7.14.3. Examples

    +
    +
    +
    state machine MonitorSm {
    +
    +}
    +
    +@ state machine monitor1 is an instance of state machine model MonitorSm
    +state machine instance monitor1 : MonitorSm
    +
    +
    +
    +
    +
    +

    7.15. Telemetry Channel Specifiers

    A telemetry channel definition defines a telemetry channel as part of a component definition.

    -

    6.14.1. Syntax

    +

    7.15.1. Syntax

    telemetry identifier : type-name @@ -5124,7 +5952,7 @@

    6.14.1. Syntax

    -

    6.14.2. Semantics

    +

    7.15.2. Semantics

    1. @@ -5194,7 +6022,7 @@

      6.14.2. Semantics

    -

    6.14.3. Examples

    +

    7.15.3. Examples

    @ An array of 3 F64 values
    @@ -5223,18 +6051,18 @@ 

    6.14.3. Examples

    -

    6.15. Topology Import Specifiers

    +

    7.16. Topology Import Specifiers

    A topology import specifier imports one topology into another one.

    -

    6.15.1. Syntax

    +

    7.16.1. Syntax

    import qual-ident

    -

    6.15.2. Semantics

    +

    7.16.2. Semantics

    The qualified identifier must refer to @@ -5325,7 +6153,7 @@

    6.15.2. Semantics

    -

    6.15.3. Example

    +

    7.16.3. Example

    topology A {
    @@ -5415,7 +6243,7 @@ 

    6.15.3. Example

    -

    7. Port Instance Identifiers

    +

    8. Port Instance Identifiers

    A port instance identifier identifies a port instance @@ -5424,7 +6252,7 @@

    7. Port Instance Identifiers

    connection graph specifiers.

    -

    7.1. Syntax

    +

    8.1. Syntax

    qual-ident . @@ -5432,7 +6260,7 @@

    7.1. Syntax

    -

    7.2. Semantics

    +

    8.2. Semantics

    For each port instance identifier Q . P:

    @@ -5461,7 +6289,7 @@

    7.2. Semantics

    -

    7.3. Examples

    +

    8.3. Examples

    a.b
    @@ -5478,7 +6306,7 @@ 

    7.3. Examples

    -

    8. Type Names

    +

    9. Type Names

    Type names are the syntactic names of @@ -5490,7 +6318,7 @@

    8. Type Names

    a.b and the name b may refer to the same array type.

    -

    8.1. Primitive Integer Type Names

    +

    9.1. Primitive Integer Type Names

    Primitive integer type names are the names of the primitive integer types. @@ -5515,7 +6343,7 @@

    8.1. Primitive Integer Type Nam

    -

    8.2. Floating-Point Type Names

    +

    9.2. Floating-Point Type Names

    The floating-point type names are F32 and F64. These refer to the types of IEEE @@ -5523,14 +6351,14 @@

    8.2. Floating-Point Type Names

    -

    8.3. The Boolean Type Name

    +

    9.3. The Boolean Type Name

    The type name bool represents the type of the two Boolean values true and false.

    -

    8.4. String Type Names

    +

    9.4. String Type Names

    A string type name consists of the keyword string optionally followed by the keyword size and an @@ -5554,7 +6382,7 @@

    8.4. String Type Names

    -

    8.5. Qualified Identifier Type Names

    +

    9.5. Qualified Identifier Type Names

    -

    9. Expressions

    +

    10. Expressions

    -

    9.1. Arithmetic Expressions

    +

    10.1. Arithmetic Expressions

    FPP includes the following arithmetic expressions:

    @@ -5672,12 +6500,12 @@

    9.1. Arithmetic Expressions

    -

    9.2. Array Expressions

    +

    10.2. Array Expressions

    An array expression is an expression that represents an array value.

    -

    9.2.1. Syntax

    +

    10.2.1. Syntax

    [ array-element-sequence ]

    @@ -5690,7 +6518,7 @@

    9.2.1. Syntax

    -

    9.2.2. Semantics

    +

    10.2.2. Semantics

    1. @@ -5709,7 +6537,7 @@

      9.2.2. Semantics

    -

    9.2.3. Example

    +

    10.2.3. Example

    constant a = [ 0, 1, 2 ] # a is an array value with elements 0, 1, 2
    @@ -5718,13 +6546,13 @@

    9.2.3. Example

    -

    9.3. Boolean Literals

    +

    10.3. Boolean Literals

    A Boolean literal expression is one of the values true and false.

    -

    9.4. Dot Expressions

    +

    10.4. Dot Expressions

    A dot expression is a use @@ -5734,7 +6562,7 @@

    9.4. Dot Expressions

    enumerated constant definition.

    -

    9.4.1. Syntax

    +

    10.4.1. Syntax

    expression . @@ -5742,7 +6570,7 @@

    9.4.1. Syntax

    -

    9.4.2. Semantics

    +

    10.4.2. Semantics

    The following rules give the meaning of a dot expression \$e\$.x:

    @@ -5764,7 +6592,7 @@

    9.4.2. Semantics

    -

    9.4.3. Examples

    +

    10.4.3. Examples

    Example 1
    @@ -5788,7 +6616,7 @@
    Example 2
    -

    9.5. Floating-Point Literals

    +

    10.5. Floating-Point Literals

    A floating-point literal expression is a C-style representation of an IEEE floating-point number.

    @@ -5806,7 +6634,7 @@

    9.5. Floating-Point Literals

    -

    9.6. Identifier Expressions

    +

    10.6. Identifier Expressions

    An identifier expression is an identifier @@ -5828,7 +6656,7 @@

    9.6. Identifier Expressions

    -

    9.7. Integer Literals

    +

    10.7. Integer Literals

    An integer literal expression is one of the following:

    @@ -5863,14 +6691,14 @@

    9.7. Integer Literals

    -

    9.8. Parenthesis Expressions

    +

    10.8. Parenthesis Expressions

    A parenthesis expression is an expression surrounded by parentheses in order to group subexpressions and to force evaluation order.

    -

    9.8.1. Syntax

    +

    10.8.1. Syntax

    ( expression @@ -5878,13 +6706,13 @@

    9.8.1. Syntax

    -

    9.8.2. Semantics

    +

    10.8.2. Semantics

    The type and value of the expression are the type and value of the subexpression.

    -

    9.8.3. Example

    +

    10.8.3. Example

    constant a = (1 + 2) * 3
    @@ -5897,7 +6725,7 @@

    9.8.3. Example

    -

    9.9. String Literals

    +

    10.9. String Literals

    A string literal expression is a single-line string literal or a multiline string literal. @@ -5927,7 +6755,7 @@

    9.9. String Literals

    -

    9.9.1. Single-Line String Literals

    +

    10.9.1. Single-Line String Literals

    A single-line string literal is a sequence of single-line literal characters enclosed in double @@ -5983,7 +6811,7 @@

    9.9.1. Single-L

    -

    9.9.2. Multiline String Literals

    +

    10.9.2. Multiline String Literals

    A multiline string literal is a sequence of multiline literal characters enclosed in sequences """ of three double quote characters. @@ -6069,12 +6897,12 @@

    9.9.2. Multiline

    -

    9.10. Struct Expressions

    +

    10.10. Struct Expressions

    An struct expression is an expression that represents a struct value.

    -

    9.10.1. Syntax

    +

    10.10.1. Syntax

    { struct-element-sequence }

    @@ -6089,7 +6917,7 @@

    9.10.1. Syntax

    -

    9.10.2. Semantics

    +

    10.10.2. Semantics

    The following must be true of the struct element sequence S:

    @@ -6110,7 +6938,7 @@

    9.10.2. Semantics

    -

    9.10.3. Example

    +

    10.10.3. Example

    # s is a struct value with members x = 0, y = 1
    @@ -6123,7 +6951,7 @@ 

    9.10.3. Example

    -

    9.11. Precedence and Associativity

    +

    10.11. Precedence and Associativity

    Ambiguity in parsing expressions is resolved with the following precedence table. Expressions appearing earlier in the table @@ -6165,7 +6993,7 @@

    9.11. Precedence and Associati

    -

    10. Formal Parameter Lists

    +

    11. Formal Parameter Lists

    A formal parameter list is an @@ -6180,7 +7008,7 @@

    10. Formal Parameter Lists

    port definitions.

    -

    10.1. Syntax

    +

    11.1. Syntax

    Formal parameters have the following syntax:

    @@ -6192,7 +7020,7 @@

    10.1. Syntax

    -

    10.2. Semantics

    +

    11.2. Semantics

    If present, the keyword ref specifies that the value bound to the formal parameter is to be passed by reference @@ -6208,7 +7036,7 @@

    10.2. Semantics

    -

    10.3. Examples

    +

    11.3. Examples

    a: U32
    @@ -6220,7 +7048,7 @@ 

    10.3. Examples

    -

    11. Format Strings

    +

    12. Format Strings

    A format string is a string that specifies the display format @@ -6322,10 +7150,10 @@

    11. Format Strings

    -

    12. Comments and Annotations

    +

    13. Comments and Annotations

    -

    12.1. Comments

    +

    13.1. Comments

    A comment is model text that is ignored by the translator. It provides information to human readers of the source model.

    @@ -6350,7 +7178,7 @@

    12.1. Comments

    -

    12.2. Annotations

    +

    13.2. Annotations

    An annotation is similar to a comment, but it is attached to a @@ -6360,7 +7188,7 @@

    12.2. Annotations

    is to include annotations as comments in generated code.

    -

    12.2.1. Where Annotations Can Occur

    +

    13.2.1. Where Annotations Can Occur

    Annotations can occur at the following syntax elements:

    @@ -6385,7 +7213,7 @@

    12.2.1

    -

    12.2.2. Kinds of Annotations

    +

    13.2.2. Kinds of Annotations

    There are two kinds of annotations: pre-annotations and post-annotations.

    @@ -6426,7 +7254,7 @@
    Examp
    -

    12.2.3. Multiline Annotations

    +

    13.2.3. Multiline Annotations

    You can write several pre-annotations in a row before an annotatable element e. @@ -6467,10 +7295,10 @@

    Exam
    -

    13. Translation Units and Models

    +

    14. Translation Units and Models

    -

    13.1. Translation Units

    +

    14.1. Translation Units

    A translation unit forms part of a model at the top level. @@ -6479,7 +7307,7 @@

    13.1. Translation Units< e.g., on standard input.

    -

    13.1.1. Syntax

    +

    14.1.1. Syntax

    A translation unit is an element sequence in which each @@ -6490,7 +7318,7 @@

    13.1.1. Syntax

    -

    13.1.2. Example

    +

    14.1.2. Example

    Here is a translation unit:

    @@ -6525,7 +7353,7 @@

    13.1.2. Example<

    -

    13.2. Models

    +

    14.2. Models

    A model is a collection of one or more translation @@ -6581,7 +7409,7 @@

    13.2. Models

    -

    13.3. Locations

    +

    14.3. Locations

    Every syntactic element E in a source model has an associated location L. @@ -6606,10 +7434,10 @@

    13.3. Locations

    -

    14. Scoping of Names

    +

    15. Scoping of Names

    -

    14.1. Qualified Identifiers

    +

    15.1. Qualified Identifiers

    A qualified identifier is one of the following:

    @@ -6637,7 +7465,7 @@

    14.1. Qualified Identifiers

    -

    14.3. Name Groups

    +

    15.3. Name Groups

    The qualified names of definitions and reside in the following name groups:

    @@ -6752,9 +7580,9 @@

    14.3. Name Groups

    -

    14.4. Multiple Definitions with the Same Qualified Name

    +

    15.4. Multiple Definitions with the Same Qualified Name

    -

    14.4.1. Different Name Groups

    +

    15.4.1. Different Name Groups

    Two definitions with the same qualified name are allowed if they are in different name groups. For example:

    @@ -6767,7 +7595,7 @@

    -

    14.4.2. Module Definitions

    +

    15.4.2. Module Definitions

    Multiple syntactic module definitions with the same qualified name are allowed. The semantic analysis combines all such definitions into a @@ -6809,7 +7637,7 @@

    -

    14.4.3. Conflicting Definitions

    +

    15.4.3. Conflicting Definitions

    Within the same name group, two definitions with the same qualified name are not allowed, unless they are both module definitions @@ -6838,7 +7666,7 @@

    -

    14.5. Resolution of Identifiers

    +

    15.5. Resolution of Identifiers

    The following rules govern the resolution of identifiers, i.e., associating identifiers with definitions:

    @@ -6939,7 +7767,7 @@

    14.5. Resolution of Identifi

    -

    14.6. Resolution of Qualified Identifiers

    +

    15.6. Resolution of Qualified Identifiers

    The following rules govern the resolution of qualified identifiers, i.e., @@ -7009,10 +7837,10 @@

    14.6. Resolution o

    -

    15. Definitions and Uses

    +

    16. Definitions and Uses

    -

    15.1. Uses

    +

    16.1. Uses

    A use is a qualified identifier @@ -7052,7 +7880,7 @@

    15.1. Uses

    -

    15.2. Use-Def Graph

    +

    16.2. Use-Def Graph

    The set of definitions and non-qualifying uses @@ -7119,7 +7947,7 @@

    15.2. Use-Def Graph

    -

    15.3. Order of Definitions and Uses

    +

    16.3. Order of Definitions and Uses

    So long as the use-def graph is acyclic, there is no @@ -7162,10 +7990,10 @@

    15.3. Order of Defin

    -

    16. Types

    +

    17. Types

    -

    16.1. Primitive Integer Types

    +

    17.1. Primitive Integer Types

    The primitive integer types correspond to the primitive integer type names @@ -7173,7 +8001,7 @@

    16.1. Primitive Integer Types

    -

    16.2. Floating-Point Types

    +

    17.2. Floating-Point Types

    The floating-point types correspond to the floating-point type names @@ -7181,7 +8009,7 @@

    16.2. Floating-Point Types

    -

    16.3. Primitive Numeric Types

    +

    17.3. Primitive Numeric Types

    The primitive integer types together with the floating-point types are @@ -7189,7 +8017,7 @@

    16.3. Primitive Numeric Types

    -

    16.4. The Boolean Type

    +

    17.4. The Boolean Type

    The Boolean type corresponds to the Boolean type name. @@ -7197,7 +8025,7 @@

    16.4. The Boolean Type

    -

    16.5. Primitive Types

    +

    17.5. Primitive Types

    Together, the primitive numeric types and the @@ -7206,7 +8034,7 @@

    16.5. Primitive Types

    -

    16.6. String Types

    +

    17.6. String Types

    The string types correspond to the string type names. @@ -7217,7 +8045,7 @@

    16.6. String Types

    -

    16.7. Array Types

    +

    17.7. Array Types

    An array type is a type associated with an array definition. @@ -7230,7 +8058,7 @@

    16.7. Array Types

    -

    16.8. Enum Types

    +

    17.8. Enum Types

    An enum type is a type associated with an enum definition. @@ -7241,7 +8069,7 @@

    16.8. Enum Types

    -

    16.9. Struct Types

    +

    17.9. Struct Types

    A struct type is a type associated with a struct definition. @@ -7252,7 +8080,7 @@

    16.9. Struct Types

    -

    16.10. Abstract Types

    +

    17.10. Abstract Types

    An abstract type is a type associated with an abstract type definition. @@ -7263,20 +8091,20 @@

    16.10. Abstract Types

    -

    16.11. Internal Types

    +

    17.11. Internal Types

    Internal types do not have syntactic names in FPP source models. The compiler assigns these types to expressions during type checking.

    -

    16.11.1. Integer

    +

    17.11.1. Integer

    The type Integer represents all integer values, without regard to bit width.

    -

    16.11.2. Integer Types

    +

    17.11.2. Integer Types

    Integer together with the primitive integer types are called @@ -7284,7 +8112,7 @@

    16.11.2. Integer Types

    -

    16.11.3. Numeric Types

    +

    17.11.3. Numeric Types

    Integer together with the primitive numeric types are called @@ -7292,7 +8120,7 @@

    16.11.3. Numeric Types

    -

    16.11.4. Anonymous Array Types

    +

    17.11.4. Anonymous Array Types

    The type [ n ] T, where n is an integer and T is a type, represents an array of n elements, @@ -7300,7 +8128,7 @@

    16.11.4. Anonymous Array Typ

    -

    16.11.5. Anonymous Struct Types

    +

    17.11.5. Anonymous Struct Types

    The type { \$m_1\$ : \$T_1, ...,\$ \$m_n\$ : \$T_n\$ }, where each \$m_i\$ is an identifier and each \$T_i\$ is a type, @@ -7314,7 +8142,7 @@

    16.11.5. Anonymous Struct T

    -

    16.12. Types with Numeric Members

    +

    17.12. Types with Numeric Members

    A type has numeric members if it is one of the following:

    @@ -7337,7 +8165,7 @@

    16.12. Types with Numeric Members

    -

    16.13. Default Values

    +

    17.13. Default Values

    Every type T with a syntactic name in FPP has an associated default value. @@ -7399,7 +8227,7 @@

    16.13. Default Values

    -

    17. Type Checking

    +

    18. Type Checking

    In this section, we explain the rules used to assign types to @@ -7427,7 +8255,7 @@

    17. Type Checking

    the result is a value of type \$T\$.

    -

    17.1. Integer Literals

    +

    18.1. Integer Literals

    -

    17.2. Floating-Point Literals

    +

    18.2. Floating-Point Literals

    -

    17.5. Identifier Expressions

    +

    18.5. Identifier Expressions

    To type an identifier expression \$e\$, the semantic analyzer @@ -7499,7 +8327,7 @@

    17.5. Identifier Expressions

    -

    17.6. Dot Expressions

    +

    18.6. Dot Expressions

    -

    17.8. Struct Expressions

    +

    18.8. Struct Expressions

    To type a struct expression @@ -7599,7 +8427,7 @@

    17.8. Struct Expressions

    -

    17.9. Unary Negation Expressions

    +

    18.9. Unary Negation Expressions

    -

    17.11. Parenthesis Expressions

    +

    18.11. Parenthesis Expressions

    -

    17.12. Identical Types

    +

    18.12. Identical Types

    We say that types \$T_1\$ and \$T_2\$ are identical if one of the following holds:

    @@ -7743,7 +8571,7 @@

    17.12. Identical Types

    -

    17.14. Computing a Common Type

    +

    18.14. Computing a Common Type

    -

    17.14.1. Pairs of Types

    +

    18.14.1. Pairs of Types

    Here are the rules for resolving two types \$T_1\$ and \$T_2\$ (e.g., the @@ -7938,7 +8766,7 @@

    17.14.1. Pairs of

    -

    17.14.2. Lists of Types

    +

    18.14.2. Lists of Types

    To compute a common type for a list of types \$T_1, ... , T_n\$, do the following:

    @@ -7975,7 +8803,7 @@

    17.14.2. Lists of

    -

    18. Values

    +

    19. Values

    A value is one of the following:

    @@ -8021,7 +8849,7 @@

    18. Values

    Every value belongs to exactly one type.

    -

    18.1. Primitive Integer Values

    +

    19.1. Primitive Integer Values

    A primitive integer value is an ordinary (mathematical) integer value together with a @@ -8051,7 +8879,7 @@

    18.1. Primitive Integer Values

    -

    18.2. Integer Values

    +

    19.2. Integer Values

    An integer value is an ordinary (mathematical) integer value. It has type Integer. @@ -8060,7 +8888,7 @@

    18.2. Integer Values

    -

    18.3. Floating-Point Values

    +

    19.3. Floating-Point Values

    A floating-point value is an IEEE floating-point value of 4- or 8-byte width. Formally, the set of floating-point values is the disjoint union @@ -8082,14 +8910,14 @@

    18.3. Floating-Point Values

    -

    18.4. Boolean Values

    +

    19.4. Boolean Values

    A Boolean value is one of the values true and false. Its type is bool.

    -

    18.5. String Values

    +

    19.5. String Values

    A string value is a sequence of characters that can be represented as a string literal expression. @@ -8099,7 +8927,7 @@

    18.5. String Values

    -

    18.6. Abstract Type Values

    +

    19.6. Abstract Type Values

    An abstract type value is a value associated with an abstract type. @@ -8108,7 +8936,7 @@

    18.6. Abstract Type Values

    -

    18.7. Anonymous Array Values

    +

    19.7. Anonymous Array Values

    An anonymous array value is a value associated with an anonymous array type. @@ -8121,7 +8949,7 @@

    18.7. Anonymous Array Values

    -

    18.8. Array Values

    +

    19.8. Array Values

    An array value is a value associated with an array type. We write an array value like an anonymous array @@ -8152,7 +8980,7 @@

    18.8. Array Values

    -

    18.10. Anonymous Struct Values

    +

    19.10. Anonymous Struct Values

    An anonymous struct value is a value associated with an anonymous struct @@ -8179,7 +9007,7 @@

    18.10. Anonymous Struct Values

    -

    18.12. Serialized Sizes

    +

    19.12. Serialized Sizes

    Every value v whose type has a syntactic representation in FPP has a serialized size. This is the number of bytes required to represent v in @@ -8263,7 +9091,7 @@

    18.12. Serialized Sizes

    -

    19. Evaluation

    +

    20. Evaluation

    Evaluation is the process of transforming an expression into @@ -8273,7 +9101,7 @@

    19. Evaluation

    in resolving expressions to compile-time constant values.

    -

    19.1. Evaluating Expressions

    +

    20.1. Evaluating Expressions

    Evaluation of expressions occurs as stated in the expression descriptions. Evaluation of integer @@ -8284,14 +9112,14 @@

    19.1. Evaluating Expressions

    -

    19.2. Type Conversion

    +

    20.2. Type Conversion

    The following rules govern the conversion of a value \$v_1\$ of type \$T_1\$ to a value \$v_2\$ of type \$T_2\$.

    -

    19.2.1. Unsigned Primitive Integer Values

    +

    20.2.1. Unsigned Primitive Integer Values

    1. @@ -8313,7 +9141,7 @@

      19.2.1. Un

    -

    19.2.2. Signed Primitive Integer Values

    +

    20.2.2. Signed Primitive Integer Values

    1. @@ -8333,7 +9161,7 @@

      19.2.2. Sign

    -

    19.2.3. Primitive Integer Values of Mixed Sign

    +

    20.2.3. Primitive Integer Values of Mixed Sign

    If \$T_1\$ and \$T_2\$ are primitive integer types with one signed and one unsigned, @@ -8358,7 +9186,7 @@

    19.2.

    -

    19.2.4. Primitive and Non-Primitive Integer Values

    +

    20.2.4. Primitive and Non-Primitive Integer Values

    If \$T_1\$ is Integer and \$T_2\$ is a primitive integer type, then proceed as if \$T_1\$ were a signed primitive integer @@ -8373,7 +9201,7 @@

    1

    -

    19.2.5. Floating-Point Values

    +

    20.2.5. Floating-Point Values

    We use the standard rules for IEEE floating-point values to convert among integer values to and from floating-point values and @@ -8381,7 +9209,7 @@

    19.2.5. Floating-Point

    -

    19.2.6. Array Values

    +

    20.2.6. Array Values

    If \$T_2\$ is an array type and \$T_1 = T_2\$, then let \$v_2 = v_1\$.

    @@ -8409,7 +9237,7 @@

    19.2.6. Array Values

    -

    19.2.7. Structure Values

    +

    20.2.7. Structure Values

    If \$T_2\$ is a struct type and \$T_1 = T_2\$, then let \$v_2 = v_1\$.

    @@ -8443,10 +9271,10 @@

    19.2.7. Structure Values

    -

    20. Analysis and Translation

    +

    21. Analysis and Translation

    -

    20.1. Analysis

    +

    21.1. Analysis

    Analysis is the process of checking a source model. It usually involves the following steps:

    @@ -8463,7 +9291,7 @@

    20.1. Analysis

    -

    20.2. Analysis Tools

    +

    21.2. Analysis Tools

    An analysis tool is a tool that reads in and analyzes FPP source files, but does not generate any code. @@ -8487,7 +9315,7 @@

    20.2. Analysis Tools

    -

    20.3. Translation

    +

    21.3. Translation

    Translation is the process of performing analysis and generating code.

    @@ -8512,7 +9340,7 @@

    20.3. Translation

    -

    20.4. Translation Tools

    +

    21.4. Translation Tools

    A translation tool is a tool that translates FPP source files. A translation tool typically accepts the following two kinds of @@ -8551,9 +9379,10 @@

    20.4. Translation Tools

    + - + \ No newline at end of file diff --git a/docs/fpp-users-guide.html b/docs/fpp-users-guide.html index 88e12caf8..311be8483 100644 --- a/docs/fpp-users-guide.html +++ b/docs/fpp-users-guide.html @@ -4,23 +4,25 @@ - + The F Prime Prime (FPP) User’s Guide, Unreleased, after v2.0.2 - + - + \ No newline at end of file diff --git a/docs/index.html b/docs/index.html index d0a1300ac..a5b86e721 100644 --- a/docs/index.html +++ b/docs/index.html @@ -4,23 +4,25 @@ - + F Prime Prime (FPP) +