In using it in a named association array aggregate, its semantic are
"and" --- e.g., some_1D_array := (1 | 3 | 7 => 5, others => 10) sets
elements 1 and 3 and 7 to the value 5. In a case statement, its
semantics are "or" --- e.g. when 1 | 3 | 7 => ... any of the values
1, 3, or 7 for the case expression will select the ... code for
execution. Is there a single name for that symbol (the | ) that seems
to have different semantics depending on context?
In using it in a named association array aggregate, its semantics are
"and" --- e.g., some_1D_array := (1 | 3 | 7 => 5, others => 10) sets
elements 1 and 3 and 7 to the value 5. In a case statement, its
semantics are "or" --- e.g. when 1 | 3 | 7 => ... any of the values
1or 3, or 7 for the case expression will select the ... code for
execution.
Is there a single name for that symbol (the | ) that seems
to have different semantics depending on context?
In using it in a named association array aggregate, its semantic are "and" --- e.g., some_1D_array := (1 | 3 | 7 => 5, others => 10) sets elements 1 and 3 and 7 to the value 5. In a case statement, its semantics are "or" --- e.g. when 1 | 3 | 7 => ...any of the values 1, 3, or 7 for the case expression will select the ... code for execution. Is there a single name for that symbol (the | ) that seems to have different semantics depending on context?
On 2022-03-25 20:04, Matt Jaffe wrote:
In using it in a named association array aggregate, its semantic are
"and" --- e.g., some_1D_array := (1 | 3 | 7 => 5, others => 10) sets
elements 1 and 3 and 7 to the value 5. In a case statement, its
semantics are "or" --- e.g. when 1 | 3 | 7 => ... any of the values
1, 3, or 7 for the case expression will select the ... code for
execution. Is there a single name for that symbol (the | ) that
seems to have different semantics depending on context?
ARM 2.1(15/3) (http://www.ada-auth.org/standards/aarm12_w_tc1/html/AA-2-1.html#I1201)
says its name in Ada is "vertical line".
Probably wrong, but for a Unix user since the last century, I call it
'pipe'
On 25/03/2022 23:24, Chris Townley wrote:
Probably wrong, but for a Unix user since the last century, I call it
'pipe'
Or bar.
For the name, see https://en.wikipedia.org/wiki/Vertical_bar
On 25/03/2022 23:24, Chris Townley wrote:
Probably wrong, but for a Unix user since the last century, I call
it 'pipe'
Or bar.
On 25/03/2022 22:21, Jeffrey R.Carter wrote:
On 2022-03-25 20:04, Matt Jaffe wrote:
In using it in a named association array aggregate, its semantic are
"and" --- e.g., some_1D_array := (1 | 3 | 7 => 5, others => 10) sets
elements 1 and 3 and 7 to the value 5. In a case statement, its
semantics are "or" --- e.g. when 1 | 3 | 7 => ... any of the values
1, 3, or 7 for the case expression will select the ... code for
execution. Is there a single name for that symbol (the | ) that
seems to have different semantics depending on context?
ARM 2.1(15/3) (http://www.ada-auth.org/standards/aarm12_w_tc1/html/AA-2-1.html#I1201) says its name in Ada is "vertical line".
Probably wrong, but for a Unix user since the last century, I call it 'pipe'
--
Chris
"Luke A. Guest" <lag...@archeia.com> writes:
On 25/03/2022 23:24, Chris Townley wrote:
Probably wrong, but for a Unix user since the last century, I call
it 'pipe'
Or bar.Emacs ada-mode grammar calls it BAR.
--
-- Stephe
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 374 |
Nodes: | 16 (2 / 14) |
Uptime: | 16:36:18 |
Calls: | 7,968 |
Calls today: | 2 |
Files: | 13,012 |
Messages: | 5,815,726 |