diff --git a/CHANGELOG.md b/CHANGELOG.md index f69bd3ec8..0eb65aeee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +## 1.34.2 + +* Fix a bug that could prevent some members from being found in certain files + that use a mix of imports and the module system. + ## 1.34.1 * Fix a bug where `--update` would always compile any file that depends on a diff --git a/lib/src/async_environment.dart b/lib/src/async_environment.dart index dedf2a402..73e0969d2 100644 --- a/lib/src/async_environment.dart +++ b/lib/src/async_environment.dart @@ -210,12 +210,19 @@ class AsyncEnvironment { /// Returns a new environment to use for an imported file. /// /// The returned environment shares this environment's variables, functions, - /// and mixins, but not its modules. + /// and mixins, but excludes most modules (except for global modules that + /// result from importing a file with forwards). AsyncEnvironment forImport() => AsyncEnvironment._( {}, {}, - {}, - {}, + { + for (var module in _globalModules) + if (module is ForwardedModuleView) module + }, + { + for (var entry in _globalModuleNodes.entries) + if (entry.key is ForwardedModuleView) entry.key: entry.value + }, null, null, null, diff --git a/lib/src/environment.dart b/lib/src/environment.dart index 5bde2aeb8..febb97494 100644 --- a/lib/src/environment.dart +++ b/lib/src/environment.dart @@ -5,7 +5,7 @@ // DO NOT EDIT. This file was generated from async_environment.dart. // See tool/grind/synchronize.dart for details. // -// Checksum: 588f0864bb1f889586178c799d91696341ecf218 +// Checksum: 0411d2d782920c2d8293eacf178941c192670e75 // // ignore_for_file: unused_import @@ -217,12 +217,19 @@ class Environment { /// Returns a new environment to use for an imported file. /// /// The returned environment shares this environment's variables, functions, - /// and mixins, but not its modules. + /// and mixins, but excludes most modules (except for global modules that + /// result from importing a file with forwards). Environment forImport() => Environment._( {}, {}, - {}, - {}, + { + for (var module in _globalModules) + if (module is ForwardedModuleView) module + }, + { + for (var entry in _globalModuleNodes.entries) + if (entry.key is ForwardedModuleView) entry.key: entry.value + }, null, null, null, diff --git a/pubspec.yaml b/pubspec.yaml index f27aad41c..327c2c250 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,5 +1,5 @@ name: sass -version: 1.34.1 +version: 1.34.2-dev description: A Sass implementation in Dart. author: Sass Team homepage: https://github.com/sass/dart-sass