LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Blogs
User Name
Password

Notices


Old

Flex Based Outline Generator

Posted 11-15-2021 at 02:36 AM by astrogeek
Updated 11-15-2021 at 02:43 AM by astrogeek

This little project was suggested by my participation in the thread Bison YACC compiler generator question in the Programming forum which was started by LQ member schmitta. It is a simple program which produces formatted outlines, or other indented text output, from plain text source files with a few simple markup options.

The original question in the linked thread related to a Flex/Bison generated parser, but as the thread progressed it seemed to me that some basic level of function...
Moderator
Views 1239 Comments 0 astrogeek is offline
Old

Outline Input Example

Posted 11-15-2021 at 02:32 AM by astrogeek

Following is an example input file for the post Flex Based Outline Generator.

Copy the text below into a file named example.txt in your build directory and pass it as input to the application described in the above linked post.

Code:
##########################################
# Example Outline Specification          #
# Outlines operation of outline parser   #
##########################################

.tcOutline Generator Outline
...
Moderator
Posted in Uncategorized
Views 333 Comments 0 astrogeek is offline
Old

Flex Outline Generator Spec File

Posted 11-15-2021 at 02:31 AM by astrogeek

Following is the Flex specification source for the post Flex Based Outline Generator.

Build instructions are included in the comments at top of the source below.

Copy and paste into a file named outline.l in your build directory. You may test your build using the example input file referenced in the above linked post.

Code:
%top{
/* Robert Allen Nov 14, 2021 astrogeek::linuxquestions.org
   License: Love and respect others as yourself, do unto
...
Moderator
Posted in Uncategorized
Views 282 Comments 0 astrogeek is offline
Old

Test Cases: Sign

Posted 10-10-2021 at 11:54 PM by astrogeek

This post is part of the Alphanumeric Calculator program group.

Test cases to validate handling of sign.

The test case input file:

Code:
cat tests_sign
#both
############ Numbers with signs
+0
+1
-0
-1
-1*-1
-1*+1
+1*-1
+1*+1
############ Numeric expressions with signs
positive zero
positive one
negative zero
negative one
negative one times
...
Moderator
Views 562 Comments 0 astrogeek is offline
Old

Test Cases: Limits

Posted 10-10-2021 at 11:53 PM by astrogeek

This post is part of the Alphanumeric Calculator program group.

Test cases to validate limits and range of expressions, undefined input errors.

Test cases input file:

Code:
cat tests_limits
/* Tests detection and reporting of limits and unexpected input
*/
######## Valid - Min/Max values
999999999999
-999999999999
nine hundred ninety nine billion nine hundred ninety nine million nine hundred ninety nine thousand nine
...
Moderator
Views 231 Comments 0 astrogeek is offline

  



All times are GMT -5. The time now is 09:00 AM.

Main Menu
Advertisement
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration