Forthic Literals

Forthic literals are words that aren’t defined per se but which the Forthic interpreter treats as words. When executed, these words simply push their value onto the stack.

Number Literals

The actual syntax for a number literal varies depending on the host language, but it includes what you might normally expect. Here are some examples:

100 -100 12.45

Date Literals

Date literals always have this format: YYYY-MM-DD. If a date is invalid, NULL is returned. For example:

2024-01-24 # Jan 24, 2024 1970-10-21 # Oct 21, 1970 2024-01-36 # NULL

Time Literals

Time literals always have this format: HH:MM . Time literals use a 24 hour clock. If a time is invalid, NULL is returned. For example:

09:30 # 9:30 AM 22:45 # 10:45 PM 95:23 # NULL