Skip to content

Commit cbac0e1

Browse files
bump: update arrayvec requirement from 0.5.2 to 0.7.2 (#400)
* bump: update arrayvec requirement from 0.5.2 to 0.7.2 Updates the requirements on [arrayvec](https://github.com/bluss/arrayvec) to permit the latest version. - [Release notes](https://github.com/bluss/arrayvec/releases) - [Changelog](https://github.com/bluss/arrayvec/blob/master/CHANGELOG.md) - [Commits](bluss/arrayvec@0.5.2...0.7.2) --- updated-dependencies: - dependency-name: arrayvec dependency-type: direct:production ... Signed-off-by: dependabot[bot] <[email protected]> * fix: replace arrayvec dependency with smallvec Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Bas Zalmstra <[email protected]>
1 parent 45cfcd2 commit cbac0e1

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

crates/mun_codegen/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ parking_lot = "0.12.0"
3232
inkwell = { version = "=0.1.0-beta.4", features = ["llvm12-0", "no-libffi-linking"]}
3333
by_address = "1.0.4"
3434
paths = { version="=0.1.0", path="../mun_paths", package="mun_paths"}
35-
smallvec = "1.6.1"
35+
smallvec = { version = "1.6.1", features=["union"] }
3636
once_cell = "1.4.0"
3737

3838
[dev-dependencies]

crates/mun_hir/Cargo.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,7 @@ ena = "0.14"
2323
drop_bomb = "0.1.4"
2424
either = "1.5.3"
2525
itertools = "0.10.0"
26-
smallvec = "1.6.1"
27-
arrayvec = "0.5.2"
26+
smallvec = { version = "1.6.1", features=["union"] }
2827

2928
[dev-dependencies]
3029
insta = "1.12.0"

crates/mun_hir/src/semantics.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ use crate::{
1818
source_analyzer::SourceAnalyzer,
1919
FileId, HirDatabase, InFile, ModuleDef, Name, PatId, PerNs, Resolver, Ty, Visibility,
2020
};
21-
use arrayvec::ArrayVec;
2221
use mun_syntax::{ast, AstNode, SyntaxNode, TextSize};
2322
use rustc_hash::FxHashMap;
23+
use smallvec::SmallVec;
2424
use std::cell::RefCell;
2525

2626
/// The primary API to get semantic information, like types, from syntax trees. Exposes the database
@@ -162,8 +162,8 @@ pub enum ScopeDef {
162162

163163
impl ScopeDef {
164164
/// Returns all the `ScopeDef`s from a `PerNs`. Never returns duplicates.
165-
pub fn all_items(def: PerNs<(ItemDefinitionId, Visibility)>) -> ArrayVec<[Self; 2]> {
166-
let mut items = ArrayVec::new();
165+
pub fn all_items(def: PerNs<(ItemDefinitionId, Visibility)>) -> SmallVec<[Self; 2]> {
166+
let mut items = SmallVec::new();
167167
match (def.take_types(), def.take_values()) {
168168
(Some(ty), None) => items.push(ScopeDef::ModuleDef(ty.0.into())),
169169
(None, Some(val)) => items.push(ScopeDef::ModuleDef(val.0.into())),

0 commit comments

Comments
 (0)