diff options
| author | Cliff Click <cliffc@acm.org> | 2025-04-21 14:18:23 -0700 |
|---|---|---|
| committer | Cliff Click <cliffc@acm.org> | 2025-07-03 09:50:14 -0700 |
| commit | 018379b0cf4e286ceacb1e39f34dd80f770e381e (patch) | |
| tree | d88eae2d5e2d9609f271ec78fb60aaf08c5aaee5 /src/main/java/com/seaofnodes/simple/sys.java | |
| parent | 49534ffa88fedb3a4ebc42094e9edb27d456e6d6 (diff) | |
| download | Simple-linear-chapter22.tar.gz Simple-linear-chapter22.zip | |
Chapter 22: A Hello, World!linear-chapter22
Co-authored-by: godalming123 <68993177+godalming123@users.noreply.github.com>
Co-authored-by: Tamás Hadházy <85063808+Hels15@users.noreply.github.com>
Diffstat (limited to 'src/main/java/com/seaofnodes/simple/sys.java')
| -rw-r--r-- | src/main/java/com/seaofnodes/simple/sys.java | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/main/java/com/seaofnodes/simple/sys.java b/src/main/java/com/seaofnodes/simple/sys.java new file mode 100644 index 00000000..45106770 --- /dev/null +++ b/src/main/java/com/seaofnodes/simple/sys.java @@ -0,0 +1,25 @@ +package com.seaofnodes.simple; + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; + + +/** Default included namespaces for Simple. + + You can think of this as {@code #include <stdio.h>} for C or {@code import java.lang.*} for Java. + */ +public abstract class sys { + + public static final String SYS; + + static { + try { + SYS = Files.readString(Path.of("src/main/smp/sys.smp")); + } + catch( Exception e ) { + throw new RuntimeException(e); + } + } + +} |
