Refine inlining.
This commit is contained in:
@@ -196,6 +196,7 @@ pub struct Module {
|
||||
|
||||
impl Default for Module {
|
||||
#[inline(always)]
|
||||
#[must_use]
|
||||
fn default() -> Self {
|
||||
Self::new()
|
||||
}
|
||||
|
@@ -42,7 +42,7 @@ impl ModuleResolversCollection {
|
||||
/// ```
|
||||
#[inline(always)]
|
||||
#[must_use]
|
||||
pub fn new() -> Self {
|
||||
pub const fn new() -> Self {
|
||||
Self(Vec::new())
|
||||
}
|
||||
/// Append a [module resolver][ModuleResolver] to the end.
|
||||
@@ -112,6 +112,7 @@ impl IntoIterator for ModuleResolversCollection {
|
||||
type IntoIter = IntoIter<Box<dyn ModuleResolver>>;
|
||||
|
||||
#[inline(always)]
|
||||
#[must_use]
|
||||
fn into_iter(self) -> Self::IntoIter {
|
||||
self.0.into_iter()
|
||||
}
|
||||
|
@@ -56,6 +56,7 @@ pub struct FileModuleResolver {
|
||||
|
||||
impl Default for FileModuleResolver {
|
||||
#[inline(always)]
|
||||
#[must_use]
|
||||
fn default() -> Self {
|
||||
Self::new()
|
||||
}
|
||||
|
@@ -134,6 +134,7 @@ impl IntoIterator for StaticModuleResolver {
|
||||
type IntoIter = IntoIter<SmartString, Shared<Module>>;
|
||||
|
||||
#[inline(always)]
|
||||
#[must_use]
|
||||
fn into_iter(self) -> Self::IntoIter {
|
||||
self.0.into_iter()
|
||||
}
|
||||
|
Reference in New Issue
Block a user