First Push

basic rule-set , main bin
This commit is contained in:
2025-10-31 02:31:33 +02:00
parent 758cb8f0e1
commit d056753069
5 changed files with 104 additions and 0 deletions

9
Compiler/Fparser.py Normal file
View File

@@ -0,0 +1,9 @@
def readfile(filepath):
with open(filepath, "r") as file:
lines = file.readlines()
for line in lines:
print(line.strip())

1
Compiler/dataTypes.py Normal file
View File

@@ -0,0 +1 @@

61
Compiler/ppc.py Normal file
View File

@@ -0,0 +1,61 @@
import configparser
import argparse
import Fparser
version = 1.0
parser = argparse.ArgumentParser(
prog="Pseudo (to) Pseudoglossa Compiler",
epilog="hi",
description="Compiles Pseudo code to psebdoglossa while adding stuff like: Rendering Functions | Math | Libraries | Srtings etc .. "
)
parser.add_argument("-d", "--devmode", action='store_true')
parser.add_argument("-f", "--file")
parser.add_argument("-p", "--project")
args = parser.parse_args()
print("Pseudo to Pseudoglossa Compiler V" + str(version))
config = configparser.ConfigParser()
print("=============================================")
def checkDeps():
import Fparser
pass
def compileSingle(file):
Fparser.readfile(file)
def runArgs():
print(str(args.file) , "|" , str(args.project))
if(str(args.file )!= "None"):
print(f"Single file Project -> {str(args.file)}")
compileSingle(str(args.file))
elif(str(args.project )!= "None"):
print(f"Using {str(args.project)} as Project folder")
checkDeps()
runArgs()

22
PseudoRules.txt Normal file
View File

@@ -0,0 +1,22 @@
*=================================================================*
| PseudoGlossa - The stupidest waste of time yet? |
| |
| Compiles Pseudo code to psebdoglossa while adding stuff like: |
| Rendering Functions | Math | Libraries | Srtings etc .. idk yet |
| |
*=================================================================*
Pseudo file tags:
To mark a file for compilation it must have a file extension of
Code File [.pc] | Denfinition File (header file) [.pd] | Library File [.pl] | Asset File [.pa]
I think im gonna add a thing that reads the top line and adds other info for the compiler.....
Pseudo code table:

11
testFile.pc Normal file
View File

@@ -0,0 +1,11 @@
App adder(){
int value1 = 0
int value2 = 0
print("total" + intToString(value1 + value2))
return 0;
}