Skip to content

Conversation

@fda-odoo
Copy link
Collaborator

No description provided.

@fda-odoo fda-odoo added this to the 1.1.0 milestone Oct 29, 2025
@fda-odoo fda-odoo requested a review from mmahrouss October 29, 2025 15:41
@fda-odoo fda-odoo self-assigned this Oct 29, 2025
@fda-odoo fda-odoo added the enhancement New feature or request label Oct 29, 2025
@mmahrouss mmahrouss removed their request for review October 30, 2025 09:48
@fda-odoo fda-odoo force-pushed the alpha-workspace-symbols-fda branch from 2fcdedc to d97c40f Compare October 30, 2025 10:41
Result contains classes and functions that contains the query.
It will return model names too, pointing to all the classes implementing it.
An empty query is returning nothing, to prevent too many results
XML_ID are returned too, but prefixed with "xmlid."
@fda-odoo fda-odoo force-pushed the alpha-workspace-symbols-fda branch from d97c40f to c1761ed Compare October 30, 2025 14:11
@fda-odoo fda-odoo marked this pull request as ready for review October 30, 2025 14:13
@fda-odoo fda-odoo requested a review from mmahrouss October 30, 2025 14:13
}

pub fn try_offset_to_position(&self, offset: usize) -> Option<Position> {
FileInfo::try_offset_to_position_with_rope(self.file_info_ast.borrow().text_rope.as_ref().expect("no rope provided"), offset)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe you want to also not expect here?

Perhaps:

Suggested change
FileInfo::try_offset_to_position_with_rope(self.file_info_ast.borrow().text_rope.as_ref().expect("no rope provided"), offset)
FileInfo::try_offset_to_position_with_rope(self.file_info_ast.borrow().text_rope.as_ref()?, offset)

Ok(Some(WorkspaceSymbolResponse::Nested(symbols)))
}

fn browse_symbol(session: &mut SessionInfo, symbol: &Rc<RefCell<Symbol>>, query: &String, parent: Option<String>, parent_path: Option<&String>, can_resolve_location_range: bool, results: &mut Vec<WorkspaceSymbol>) -> bool {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could be nice to explain what the boolean means?

It is slightly confusing that it returns true if it is cancelled

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants