View Issue Details

IDProjectCategoryView StatusLast Update
0001841Issue 8 draftsShell and Utilitiespublic2024-07-25 16:23
Reporterlanodan Assigned To 
PrioritynormalSeverityEditorialTypeError
Status ResolvedResolutionAccepted 
Product VersionDraft 4.1 
NameHaelwenn Monnier
Organization
User Reference
Sectionlex
Page Number3045-3046
Line Number102063-102097
Final Accepted Text
Summary0001841: Example given for lex(1) has rules lacking mandatory action
DescriptionAs put lines 101969-101970:
> However, the absence of an action shall not be valid, and the action lex takes in such a condition
> is undefined.

While the noop one-line comment and white space actions given in the example lines 102063-102097 lack an action.
Desired ActionAdd ; or {} as noop actions, like so:

```
--- posix8-example.l 2024-07-20 05:58:59.040261956 +0200
+++ posix8-example-fix.l 2024-07-20 06:09:40.319365549 +0200
@@ -20,8 +20,8 @@
     }
 {ID} printf("An identifier: %s\n", yytext);
 "+"|"-"|"*"|"/" printf("An operator: %s\n", yytext);
-"{"[^}\n]*"}" /* Eat up one-line comments. */
-[ \t\n]+ /* Eat up white space. */
+"{"[^}\n]*"}" ; /* Eat up one-line comments. */
+[ \t\n]+ ; /* Eat up white space. */
 . printf("Unrecognized character: %s\n", yytext);
 %%
 int main(int argc, char *argv[])
```
Tagstc1-2024

Activities

nick

2024-07-25 16:11

manager   bugnote:0006845

Rewrite the Desired Action using Mantis HTML:

Add ; or {} as noop actions, like so:

--- posix8-example.l 2024-07-20 05:58:59.040261956 +0200
+++ posix8-example-fix.l 2024-07-20 06:09:40.319365549 +0200
@@ -20,8 +20,8 @@
     }
 {ID} printf("An identifier: %s\n", yytext);
 "+"|"-"|"*"|"/" printf("An operator: %s\n", yytext);
-"{"[^}\n]*"}" /* Eat up one-line comments. */
-[ \t\n]+ /* Eat up white space. */
+"{"[^}\n]*"}" ; /* Eat up one-line comments. */
+[ \t\n]+ ; /* Eat up white space. */
 . printf("Unrecognized character: %s\n", yytext);
 %%
 int main(int argc, char *argv[])

Issue History

Date Modified Username Field Change
2024-07-20 04:11 lanodan New Issue
2024-07-20 04:11 lanodan Name => Haelwenn Monnier
2024-07-20 04:11 lanodan Section => lex
2024-07-20 04:11 lanodan Page Number => 3045-3046
2024-07-20 04:11 lanodan Line Number => 102063-102097
2024-07-25 16:11 nick Note Added: 0006845
2024-07-25 16:23 Don Cragun Status New => Resolved
2024-07-25 16:23 Don Cragun Resolution Open => Accepted
2024-07-25 16:24 Don Cragun Tag Attached: tc1-2024