Skip to content

Commit 7bebe0f

Browse files
nexxaiFractalFir
authored andcommitted
README.md - typo and format fixes
1 parent ba83619 commit 7bebe0f

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

README.md

+10-6
Original file line numberDiff line numberDiff line change
@@ -38,17 +38,18 @@ dotnet_typedef! {
3838
```
3939

4040
With this approach, the classes and APIs exposed to .NET can be easily used from other .NET languages, like F# or C#. The safety of this glue layer can be checked by the Rust compiler, which should make interop issues much less likely.
41+
4142
## C support
4243

43-
While .NET is the main foccus of my work, this project can also be used to compile Rust to C, by setting the `C_MODE` enviroment flag to `1`.
44+
While .NET is the main focus of my work, this project can also be used to compile Rust to C, by setting the `C_MODE` enviroment flag to `1`.
4445

4546
This may seem like a strange and unrelated feature, but the project was written in such a way that this is not only possible, but relatively easy.
4647

4748
My representation of .NETs IR maps nicely to C, which means that I was able to add support for compiling Rust to C in 2-3K LOC. Almost all of the codebase is reused, with the C and .NET specific code only
4849
present in the very last stage of compilation.
4950

50-
This means that, instead of having to maintain 2 separate projects, I can maintian one project. Bug fixes to the .NET side of things also fix C bugs.
51-
Because of that, the support for C in the project is almost as good as support for .NET
51+
This means that, instead of having to maintain 2 separate projects, I can maintain one project. Bug fixes to the .NET side of things also fix C bugs.
52+
Because of that, the support for C in the project is almost as good as support for .NET
5253

5354
## Current state of the project
5455

@@ -60,7 +61,9 @@ Currently, the GCC and clang C compilers are supported, with plans to add suppor
6061
for `tcc`, and maybe even `sdcc`.
6162

6263
So, you *can* compile a lot of existing Rust code, but it may not necessarily *work*.
64+
6365
### core, std, and alloc uint tests.
66+
6467
.NET
6568

6669
| Name | Pass | Faliure | Crash \ Timeout| OK precentage
@@ -77,6 +80,7 @@ C
7780
| Name | Pass | Faliure | OK precentage
7881
|--------------------|--------|-------|------|
7982
| Core tests | 1419 | 294 | 82.83% |
83+
8084
## FAQ
8185

8286
### Q: What is it?
@@ -99,16 +103,16 @@ C
99103

100104
**A**: *`rustc_codegen_clr` is only tested on Linux x86_64, with the CoreCLR runtime (more commonly known as simply the .NET runtime), on .NET 8. It should work on other platforms, but it is not guaranteed.*
101105

102-
### Q: Whata about Mono?
103-
**A** *The support for the Mono runtime is not as good as it could be. Due to not supported features and differences, 128-bit integers and checked 64-bit integer arithmetic are not supported on Mono.*
106+
### Q: What about Mono?
107+
108+
**A**: *The support for the Mono runtime is not as good as it could be. Due to not supported features and differences, 128-bit integers and checked 64-bit integer arithmetic are not supported on Mono.*
104109
*Aligned allocators(__rust_alloc) and certain intrinsics are also not supported. I plan to expand support for Mono, but my resources are limited.*
105110

106111
### Q: Are there any issues?
107112

108113
**A**: *While the backend is extensively tested, it is still far from perfect, and there are still many edge cases that may break this backend.*
109114
**A**: *Currently, there are no .NET-specific versions of `std` or .NET specific target triples. This means that you will need separate .NET assemblies for each OS.*
110115

111-
112116
## Licensing
113117

114118
`rustc_codegen_clr` is dual licensed under MIT license or Apache License, Version 2.0.

0 commit comments

Comments
 (0)