This is an example custom assistant that will help you complete the Python onboarding in VS Code. After trying it out, feel free to experiment with other blocks or create your own custom assistant.
- Always use modern C++ features (C++11/14/17/20/23) when appropriate
- Follow RAII (Resource Acquisition Is Initialization) principles
- Prefer smart pointers (std::unique_ptr, std::shared_ptr) over raw pointers
- Use std::string_view for non-owning string references when possible
- Use auto for type inference when it improves readability
- Prefer range-based for loops over traditional indexing
- Use constexpr for compile-time evaluation where possible
- Implement move semantics for resource-managing classes
- Use std::optional, std::variant, and std::any when appropriate
- Use static code analysis tools to identify potential issues
- Adhere to clang-format style conventions for consistent formatting
- Use std::array instead of C-style arrays
- Leverage structured bindings for multiple return values
- Prefer compile-time safety through strong typing
- Use noexcept specifications appropriately
- Use enum class over plain enums
- Prefer nullptr over NULL or 0 for null pointers
- Use std::span for non-owning views of contiguous sequences (C++20)
- Leverage concepts for template constraints (C++20)
- Use modules when appropriate (C++20)
- Utilize coroutines for asynchronous code (C++20)
- Apply spaceship operator <=> for comparison operations (C++20)
- Use designated initializers for clearer struct initialization (C++20)
- Use [[nodiscard]] for functions whose return values should be used
- Implement thread safety in shared resources
- Use std::format instead of printf or iostream manipulators (C++20)
- Apply consteval and constinit when appropriate (C++20)
- Avoid raw pointer ownership
- Avoid manual memory management with new/delete
- Avoid C-style casts (use static_cast, dynamic_cast, etc.)
- Avoid implicit type conversions
- Avoid global variables when not necessary
- Avoid macro usage when modern alternatives exist
- Avoid using namespace std
- Avoid exception specifications (except noexcept)
- Avoid goto statements
- Avoid non-const references as function parameters (when not modifying)
- Avoid returning references to local variables
- Avoid magic numbers without named constants
- Avoid excessive code duplication
- Avoid naked new/delete operations
- Avoid ignoring compiler warnings
- Avoid deep inheritance hierarchies
- Avoid overly complex template metaprogramming when simpler solutions exist
- Avoid undefined behavior
- Avoid premature optimization
No Docs configured
Use Cargo to write a comprehensive suite of unit tests for this function
No Data configured
No MCP Servers configured