crogarox / ccsharp Goto Github PK
View Code? Open in Web Editor NEWThis project forked from pquiring/ccsharp
CCSharp : C# to C++ cross compiler + corelib
This project forked from pquiring/ccsharp
CCSharp : C# to C++ cross compiler + corelib
CC# === C# -> C++ = CC# This is the next evolution in C# to C++ compiler based on the Q# project which tried to use attributes to inject C++ code directly into the C# source which was a mess. CC# instead uses extern functions which are defined in cpp source files, creating much cleaner code. The compiler and assembly references are built directly with csc.exe (dotnet is no longer required). The extern functions do not require a [DllImport ...] attribute so to avoid compiler warnings, include a <NoWarn>0626</NoWarn> in your .csproj files, and add -nowarn:0626 on the command line for csc.exe. Compiler ======== The C# to C++ compiler is written in C# and uses the amazing Roslyn project to analyze code. I've tried MANY times to use Java's compiler to build a similar project but it just doesn't expose enough symbol information, and converting Java to C++ or C is impossible (even tried x64 assembly). The Java language is just too abstract to implement. Just look at the problems Oracle is having with Graal. Object Ownership ================ Object.clone() Object.retain() (not possible with pure pointers - need references like the R_ project) Object.release() Object.pass() Supported C# features --------------------- Not all C# features are implemented yet. But the basics are covered, including many fixes and improvements from Q# Corelib ======= The Corelib already includes a garbage collector and basic classes (Thread, String, Console, etc.) The corelib now uses standard C# names (like System.String and System.Object) since I've figured out how to properly use the -nostdlib / -noconfig options. You don't have to use Qt, you could use Gtk instead which provides a much easier to use C API but lacks in cross-platform support. Q# relied too heavily on Qt which resulted in poor performance, so CC# will try to create classes in pure C# or use the C++ stdlib as much as possible. Windows ======= Download and install VS Build Tools. Select C++ package. Enough of C# compiler should be also installed along with it. Use the C# compiler in c:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin\Roslyn\ Linux ===== To install C# compiler: Go to https://www.mono-project.com/download/stable/#download-lin to download latest version of Mono. The version in the default repo is probably too old. Note: The generated .exe / .dll files are no different than the ones generated in Windows. Builing ======= Most building is done with scripts (scripts are for noobs) and ninja. Will improve later. Author : Peter Quiring (pquiring at gmail dot com) Version : 0.0 Release Date : ?,? 2020
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.