Skip to content

Commit

Permalink
rust: mode related files moved
Browse files Browse the repository at this point in the history
  • Loading branch information
rizsotto committed Nov 16, 2024
1 parent bcfbe95 commit 1dafa26
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 8 deletions.
4 changes: 2 additions & 2 deletions rust/bear/src/bin/bear.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// SPDX-License-Identifier: GPL-3.0-or-later

use bear::input::EventFileReader;
use bear::modes::recognition::Recognition;
use bear::modes::transformation::Transformation;
use bear::modes::{All, Intercept, Mode, Semantic};
use bear::output::OutputWriter;
use bear::recognition::Recognition;
use bear::transformation::Transformation;
use bear::{args, config};
use log;
use std::env;
Expand Down
2 changes: 0 additions & 2 deletions rust/bear/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,4 @@ pub mod input;
pub mod intercept;
pub mod modes;
pub mod output;
pub mod recognition;
pub mod semantic;
pub mod transformation;
6 changes: 4 additions & 2 deletions rust/bear/src/modes/mod.rs
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
// SPDX-License-Identifier: GPL-3.0-or-later

mod intercept;
pub mod recognition;
pub mod transformation;

use crate::input::EventFileReader;
use crate::output::OutputWriter;
use crate::recognition::Recognition;
use crate::transformation::Transformation;
use crate::{args, config};
use intercept::{InterceptEnvironment, InterceptService};
use recognition::Recognition;
use std::process::ExitCode;
use std::thread;
use transformation::Transformation;

/// The mode trait is used to run the application in different modes.
pub trait Mode {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
//! The recognition logic is implemented in the `interpreters` module.
//! Here we only handle the errors and logging them to the console.

use super::{config, intercept, semantic};
use super::super::intercept;
use super::super::semantic;
use super::config;
use std::convert::TryFrom;

pub struct Recognition {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//! It can also alter the compiler flags of the compiler calls. The actions
//! are defined in the configuration this module is given.

use super::{config, semantic};
use super::super::semantic;
use super::config;

pub enum Transformation {
None,
Expand Down

0 comments on commit 1dafa26

Please sign in to comment.