Skip to content

Commit

Permalink
Forgot to merge 'pattern' crate change.
Browse files Browse the repository at this point in the history
  • Loading branch information
rizzen-yazston committed Mar 16, 2023
1 parent c48105e commit 3c7611b
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions crates/message/src/formatter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use std::rc::Rc;
use i18n_lstring::LString;
use i18n_lexer::{Lexer, Token, TokenType};
use tree::{Tree, NodeFeatures};
use i18n_pattern::{NodeType, parse};
use i18n_pattern::{ParserResult, NodeType};
use std::collections::HashMap;
//use std::fmt; this is needed if implementing Display on something

Expand All @@ -24,20 +24,20 @@ pub struct System {

impl System {
pub fn try_new( lexer: Lexer ) -> Result<Self, String> {

Err( "Temporary error until implemented.".to_string() )
}
}

pub struct Formatter {
locale: Rc<Locale>,
ast: Tree,
parser_result: ParserResult,
}

impl Formatter {

/// Creates a Formatter for the language string.
pub fn try_new( string: LString ) -> Result<Self, String> {
Err( "Temporary error until implemented.".to_string() )
/// Creates a Formatter for the language string using parsing results.
pub fn try_new( locale: Rc<Locale>, parser_result: ParserResult ) -> Self {
Formatter { locale, parser_result }
}

/// Format the language string with supplied values.
Expand Down

0 comments on commit 3c7611b

Please sign in to comment.