Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bump: rust from 1.64.0 to 1.65.0 #477

Merged
merged 1 commit into from
Nov 12, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/mun_compiler/src/driver/display_color.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ fn terminal_support_ansi() -> bool {
fn cmd_supports_ansi() -> bool {
// Run `ver` program to find out Windows version
Command::new("cmd")
.args(&["/C", "ver"])
.args(["/C", "ver"])
.output()
.map_or(false, |output| {
String::from_utf8(output.stdout).map_or(false, |windows_version| {
Expand Down
2 changes: 1 addition & 1 deletion crates/mun_hir/src/code_model/module.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ impl Module {
if let Some(file_id) = self.file_id(db) {
let item_tree = db.item_tree(file_id);
for diagnostics in item_tree.diagnostics.iter() {
diagnostics.add_to(db, &*item_tree, sink);
diagnostics.add_to(db, &item_tree, sink);
}
}

Expand Down
2 changes: 1 addition & 1 deletion crates/mun_hir/src/db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ pub trait HirDatabase: DefDatabase + Upcast<dyn DefDatabase> {

fn parse_query(db: &dyn AstDatabase, file_id: FileId) -> Parse<SourceFile> {
let text = db.file_text(file_id);
SourceFile::parse(&*text)
SourceFile::parse(&text)
}

fn line_index_query(db: &dyn SourceDatabase, file_id: FileId) -> Arc<LineIndex> {
Expand Down
2 changes: 1 addition & 1 deletion crates/mun_hir/src/expr/scope.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ pub struct ScopeData {
impl ExprScopes {
pub(crate) fn expr_scopes_query(db: &dyn DefDatabase, def: DefWithBodyId) -> Arc<ExprScopes> {
let body = db.body(def);
Arc::new(ExprScopes::new(&*body))
Arc::new(ExprScopes::new(&body))
}

fn new(body: &Body) -> ExprScopes {
Expand Down
2 changes: 1 addition & 1 deletion crates/mun_hir/src/semantics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ impl<'db> Semantics<'db> {
let mut cache = self.source_to_definition_cache.borrow_mut();
let mut context = SourceToDefContext {
db: self.db,
cache: &mut *cache,
cache: &mut cache,
};
f(&mut context)
}
Expand Down
2 changes: 1 addition & 1 deletion crates/mun_language_server/src/from_lsp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,6 @@ pub(crate) fn file_position(
) -> anyhow::Result<FilePosition> {
let file_id = file_id(snapshot, &text_document_position.text_document.uri)?;
let line_index = snapshot.analysis.file_line_index(file_id)?;
let offset = offset(&*line_index, text_document_position.position);
let offset = offset(&line_index, text_document_position.position);
Ok(FilePosition { file_id, offset })
}
13 changes: 3 additions & 10 deletions crates/mun_memory/src/gc/mark_sweep.rs
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,6 @@ where
};

map_fields(
self,
&mut new_allocations,
&mapping.conversions,
&conversion.field_mapping,
Expand Down Expand Up @@ -320,16 +319,13 @@ where
return deleted;

#[allow(clippy::mutable_key_type)]
fn map_fields<O>(
gc: &MarkSweep<O>,
fn map_fields(
new_allocations: &mut Vec<Pin<Box<ObjectInfo>>>,
conversions: &HashMap<Type, Conversion>,
mapping: &[FieldMapping],
src: NonNull<u8>,
dest: NonNull<u8>,
) where
O: Observer<Event = Event>,
{
) {
for FieldMapping {
new_ty,
new_offset,
Expand Down Expand Up @@ -366,7 +362,6 @@ where
if is_same_struct {
// Map in-memory struct to in-memory struct
map_fields(
gc,
new_allocations,
conversions,
&conversion.as_ref().unwrap().field_mapping,
Expand All @@ -387,7 +382,6 @@ where
if is_same_struct {
// Map in-memory struct to heap-allocated struct
map_fields(
gc,
new_allocations,
conversions,
&conversion.as_ref().unwrap().field_mapping,
Expand All @@ -398,7 +392,7 @@ where
// Zero initialize heap-allocated object
unsafe {
std::ptr::write_bytes(
(*object).ptr,
object.ptr,
0,
new_ty.layout().size(),
)
Expand Down Expand Up @@ -456,7 +450,6 @@ where
// The object still needs to be mapped
// Map heap-allocated struct to in-memory struct
map_fields(
gc,
new_allocations,
conversions,
&conversion.as_ref().unwrap().field_mapping,
Expand Down
2 changes: 1 addition & 1 deletion crates/mun_skeptic/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ fn extract_tests_from_string(markdown: &str, file_stem: &str) -> Vec<Test> {
}
buf.push(text.into_string());
} else if let Block::Header(ref mut buf) = block {
buf.push_str(&*text);
buf.push_str(&text);
}
}
_ => (),
Expand Down
2 changes: 1 addition & 1 deletion crates/mun_syntax/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ impl<T: AstNode> Parse<T> {
}

pub fn errors(&self) -> &[SyntaxError] {
&*self.errors
&self.errors
}

pub fn ok(self) -> Result<T, Arc<[SyntaxError]>> {
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.64
1.65.0