Fix prefix

This commit is contained in:
Aoran Zeng 2025-07-21 03:01:27 +08:00
parent 498eabf869
commit 2300c3052c
No known key found for this signature in database
GPG Key ID: 8F8BA8488E10ED98
3 changed files with 10 additions and 10 deletions

View File

@ -81,10 +81,10 @@ sub MAIN(
exit(1);
}
my $parser = Parser::Parser.new($markdown-file.Str);
my $parser = Rawstr4c::Parser::Parser.new($markdown-file.Str);
$parser.parse;
my $generator = Generator::Generator.new($parser);
my $generator = Rawstr4c::Generator::Generator.new($parser);
if ($debug.defined) {
given $debug {

View File

@ -38,7 +38,7 @@ class SectionConfig {
}
# 如果都没找到,生成一个新值
# 当 $default 为空时,生成的是 RS4C-Nil
return Parser::ConfigItem's-Value.new($default);
return Rawstr4c::Parser::ConfigItem's-Value.new($default);
}
@ -55,7 +55,7 @@ class SectionConfig {
if ! $default.defined {
# say "DEBUG: Key <$key> is undefined";
}
return Parser::ConfigItem's-Value.new($default);
return Rawstr4c::Parser::ConfigItem's-Value.new($default);
}
@ -94,7 +94,7 @@ class SectionConfig {
$postfix = $config-postfix.string-value();
}
return Parser::ConfigItem's-Value.new($postfix);
return Rawstr4c::Parser::ConfigItem's-Value.new($postfix);
}
#| RS4C-Bool
@ -121,7 +121,7 @@ class SectionConfig {
} else {
$lang = $config-language.string-value;
}
return Parser::ConfigItem's-Value.new($lang);
return Rawstr4c::Parser::ConfigItem's-Value.new($lang);
}
@ -137,7 +137,7 @@ class SectionConfig {
} else {
$name = $config-name.string-value;
}
return Parser::ConfigItem's-Value.new($name);
return Rawstr4c::Parser::ConfigItem's-Value.new($name);
}
#| RS4C-Bool
@ -163,7 +163,7 @@ class SectionConfig {
}
$parent = $parent.parent;
}
return Parser::ConfigItem's-Value.new($current-namespace);
return Rawstr4c::Parser::ConfigItem's-Value.new($current-namespace);
}

View File

@ -58,7 +58,7 @@ my class CVariableNameGenerator {
method generate($section) {
my $config = Config::SectionConfig.new($section);
my $config = Rawstr4c::Config::SectionConfig.new($section);
my $prefix = $config.prefix.string-value;
my $postfix = $config.postfix.string-value;
@ -222,7 +222,7 @@ class Generator {
my $title = $section.title;
my $rawstr = $section.codeblock;
my $config = Config::SectionConfig.new($section);
my $config = Rawstr4c::Config::SectionConfig.new($section);
my $debug-in-config = $config.debug.bool-value;