version bump

This commit is contained in:
2025-12-13 00:35:31 -07:00
parent 9de59ee3b1
commit 378c7e18cd
8 changed files with 12 additions and 12 deletions

View File

@@ -1,5 +1,11 @@
# Changelog # Changelog
[0.3.0]
- Implemented a multi-pass optimizer
- This should significantly reduce line count in the final output
- Fixed source map to line up with newly optimized code
[0.2.4] [0.2.4]
- Groundwork laid to collect and track source maps - Groundwork laid to collect and track source maps

View File

@@ -2,7 +2,7 @@
<ModMetadata xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <ModMetadata xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Name>Slang</Name> <Name>Slang</Name>
<Author>JoeDiertay</Author> <Author>JoeDiertay</Author>
<Version>0.2.4</Version> <Version>0.3.0</Version>
<Description> <Description>
[h1]Slang: High-Level Programming for Stationeers[/h1] [h1]Slang: High-Level Programming for Stationeers[/h1]

View File

@@ -41,7 +41,7 @@ namespace Slang
{ {
public const string PluginGuid = "com.biddydev.slang"; public const string PluginGuid = "com.biddydev.slang";
public const string PluginName = "Slang"; public const string PluginName = "Slang";
public const string PluginVersion = "0.2.4"; public const string PluginVersion = "0.3.0";
public static Mod MOD = new Mod(PluginName, PluginVersion); public static Mod MOD = new Mod(PluginName, PluginVersion);

View File

@@ -5,7 +5,7 @@
<Nullable>enable</Nullable> <Nullable>enable</Nullable>
<AssemblyName>StationeersSlang</AssemblyName> <AssemblyName>StationeersSlang</AssemblyName>
<Description>Slang Compiler Bridge</Description> <Description>Slang Compiler Bridge</Description>
<Version>0.2.4</Version> <Version>0.3.0</Version>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks> <AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<LangVersion>latest</LangVersion> <LangVersion>latest</LangVersion>
</PropertyGroup> </PropertyGroup>

View File

@@ -930,7 +930,7 @@ checksum = "e3a9fe34e3e7a50316060351f37187a3f546bce95496156754b601a5fa71b76e"
[[package]] [[package]]
name = "slang" name = "slang"
version = "0.2.4" version = "0.3.0"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"clap", "clap",

View File

@@ -1,6 +1,6 @@
[package] [package]
name = "slang" name = "slang"
version = "0.2.4" version = "0.3.0"
edition = "2021" edition = "2021"
[workspace] [workspace]

View File

@@ -30,7 +30,7 @@ impl<'a> Instructions<'a> {
pub fn into_inner(self) -> Vec<InstructionNode<'a>> { pub fn into_inner(self) -> Vec<InstructionNode<'a>> {
self.0 self.0
} }
pub fn write(self, writer: &mut BufWriter<dyn Write>) -> Result<(), std::io::Error> { pub fn write<W: Write>(self, writer: &mut BufWriter<W>) -> Result<(), std::io::Error> {
for node in self.0 { for node in self.0 {
writer.write_all(node.to_string().as_bytes())?; writer.write_all(node.to_string().as_bytes())?;
writer.write_all(b"\n")?; writer.write_all(b"\n")?;

View File

@@ -423,11 +423,6 @@ fn register_forwarding<'a>(
break; break;
} }
// Reg15 is a return register.
if temp_reg == 15 {
break;
}
// If we hit a label/jump, we assume liveness might leak (conservative safety) // If we hit a label/jump, we assume liveness might leak (conservative safety)
if matches!( if matches!(
node.instruction, node.instruction,
@@ -871,4 +866,3 @@ fn remove_unreachable_code<'a>(
} }
(output, changed) (output, changed)
} }