Fix feature builds.
This commit is contained in:
parent
a5d6392107
commit
e059ca009c
@ -9,16 +9,13 @@ pub struct Point {
|
||||
#[export_module]
|
||||
pub mod test_module {
|
||||
pub use super::Point;
|
||||
pub fn test_fn(input: Pointer) -> bool {
|
||||
pub fn test_fn(input: Point) -> bool {
|
||||
input.x < input.y
|
||||
}
|
||||
}
|
||||
|
||||
fn main() {
|
||||
let n = Point {
|
||||
x: 0.0,
|
||||
y: 10.0,
|
||||
};
|
||||
let n = Point { x: 0.0, y: 10.0 };
|
||||
if test_module::test_fn(n) {
|
||||
println!("yes");
|
||||
} else {
|
||||
|
@ -1,13 +1,12 @@
|
||||
//! Configuration settings for [`Engine`].
|
||||
|
||||
use crate::stdlib::{
|
||||
format,
|
||||
num::{NonZeroU64, NonZeroU8, NonZeroUsize},
|
||||
string::String,
|
||||
};
|
||||
use crate::stdlib::{format, num::NonZeroU8, string::String};
|
||||
use crate::token::Token;
|
||||
use crate::Engine;
|
||||
|
||||
#[cfg(not(feature = "unchecked"))]
|
||||
use crate::stdlib::num::{NonZeroU64, NonZeroUsize};
|
||||
|
||||
#[cfg(not(feature = "no_module"))]
|
||||
use crate::stdlib::boxed::Box;
|
||||
|
||||
|
@ -136,7 +136,7 @@ pub use utils::ImmutableString;
|
||||
use fn_native::Locked;
|
||||
|
||||
#[cfg(feature = "internals")]
|
||||
pub use utils::{calc_native_fn_hash, calc_script_fn_hash};
|
||||
pub use utils::{calc_native_fn_hash, calc_script_fn_hash, HashableHashMap};
|
||||
|
||||
#[cfg(not(feature = "internals"))]
|
||||
pub(crate) use utils::{calc_native_fn_hash, calc_script_fn_hash};
|
||||
@ -184,8 +184,7 @@ pub use token::{get_next_token, parse_string_literal, InputStream, Token, Tokeni
|
||||
#[cfg(feature = "internals")]
|
||||
#[deprecated = "this type is volatile and may change"]
|
||||
pub use ast::{
|
||||
BinaryExpr, CustomExpr, Expr, FloatWrapper, FnCallExpr, HashableHashMap, Ident, ReturnType,
|
||||
ScriptFnDef, Stmt,
|
||||
BinaryExpr, CustomExpr, Expr, FloatWrapper, FnCallExpr, Ident, ReturnType, ScriptFnDef, Stmt,
|
||||
};
|
||||
|
||||
#[cfg(feature = "internals")]
|
||||
|
@ -1806,7 +1806,7 @@ impl Engine {
|
||||
#[cfg(not(feature = "unchecked"))]
|
||||
max_string_size: self.limits.max_string_size,
|
||||
#[cfg(feature = "unchecked")]
|
||||
max_string_size: 0,
|
||||
max_string_size: None,
|
||||
non_unary: false,
|
||||
comment_level: 0,
|
||||
end_with_none: false,
|
||||
|
@ -15,6 +15,7 @@ use crate::stdlib::{
|
||||
ops::{Add, AddAssign, Deref, DerefMut},
|
||||
str::FromStr,
|
||||
string::{String, ToString},
|
||||
vec::Vec,
|
||||
};
|
||||
use crate::Shared;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user