Fix various typos
Missed by the codespell CI not being functional for a period of time.
This commit is contained in:
@@ -48,10 +48,10 @@ namespace Data
|
||||
/// string. For example "EDGE1" or "FACE345" might be the names of elements that use an IndexedName.
|
||||
/// If there is then an "EDGE2", only a pointer to the original stored name "EDGE" is retained.
|
||||
///
|
||||
/// The memory efficiency of the class comes from re-using the same character storage for names that
|
||||
/// The memory efficiency of the class comes from reusing the same character storage for names that
|
||||
/// match, while retaining their differing indices. This is achieved by either using user-provided
|
||||
/// const char * names (provided as a list of typeNames and presumed to never be deallocated), or by
|
||||
/// maintaining an internal list of names that have been used before, and can be re-used later.
|
||||
/// maintaining an internal list of names that have been used before, and can be reused later.
|
||||
class AppExport IndexedName
|
||||
{
|
||||
public:
|
||||
@@ -83,7 +83,7 @@ public:
|
||||
/// that list, only a pointer to the character storage in the list is retained: the memory
|
||||
/// locations pointed at by the list must never be destroyed once they have been used to create
|
||||
/// names. If allowOthers is true (the default) then a requested name that is not in the list
|
||||
/// will be added to a static internal storage table, and its memory then re-used for later
|
||||
/// will be added to a static internal storage table, and its memory then reused for later
|
||||
/// objects with the same name. If allowOthers is false, then the name request is rejected, and
|
||||
/// the name is treated as null.
|
||||
///
|
||||
@@ -92,7 +92,7 @@ public:
|
||||
/// entire run of the program.
|
||||
/// \param allowOthers Whether a name not in allowedTypeNames is permitted. If true (the
|
||||
/// default) then a name not in allowedTypeNames is added to a static internal storage vector
|
||||
/// so that it can be re-used later without additional memory allocation.
|
||||
/// so that it can be reused later without additional memory allocation.
|
||||
IndexedName(const char* name,
|
||||
const std::vector<const char*>& allowedTypeNames,
|
||||
bool allowOthers = true)
|
||||
@@ -114,13 +114,13 @@ public:
|
||||
set(data.constData(), data.size());
|
||||
}
|
||||
|
||||
/// Given constant name and an index, re-use the existing memory for the name, not making a copy
|
||||
/// Given constant name and an index, reuse the existing memory for the name, not making a copy
|
||||
/// of it, or scanning any existing storage for it. The name must never become invalid for the
|
||||
/// lifetime of the object it names. This memory will never be re-used by another object.
|
||||
/// lifetime of the object it names. This memory will never be reused by another object.
|
||||
///
|
||||
/// \param name The name of the object. This memory is NOT copied and must be persistent.
|
||||
/// \param index A positive, non-zero integer
|
||||
/// \return An IndexedName with the given name and index, re-using the existing memory for name
|
||||
/// \return An IndexedName with the given name and index, reusing the existing memory for name
|
||||
static IndexedName fromConst(const char* name, int index)
|
||||
{
|
||||
assert(index >= 0);
|
||||
|
||||
@@ -967,7 +967,7 @@ public:
|
||||
std::string toEscapedString() const;
|
||||
|
||||
/**
|
||||
* @brief Wether the property of the object identifier is touched.
|
||||
* @brief Whether the property of the object identifier is touched.
|
||||
*
|
||||
* This method is used to determine if the property that this object
|
||||
* identifier represents is touched.
|
||||
|
||||
@@ -317,7 +317,7 @@ StringIDRef StringHasher::getID(const Data::MappedName& name, const QVector<Stri
|
||||
QByteArray::fromRawData(indexed.getType(), static_cast<int>(strlen(indexed.getType())));
|
||||
}
|
||||
else {
|
||||
// Store the entire name in _data, but temporarily re-use the existing memory
|
||||
// Store the entire name in _data, but temporarily reuse the existing memory
|
||||
tempID._data = name.dataBytes();
|
||||
}
|
||||
|
||||
|
||||
@@ -228,7 +228,7 @@ public:
|
||||
bool hasAttribute(const char* AttrName) const;
|
||||
|
||||
private:
|
||||
// all explicit template instatiations - this is for getting
|
||||
// all explicit template instantiations - this is for getting
|
||||
// a compile error, rather than linker error.
|
||||
template<typename T>
|
||||
static constexpr bool instantiated =
|
||||
@@ -237,7 +237,7 @@ private:
|
||||
|
||||
public:
|
||||
/// return the named attribute as T (does type checking); if missing return defaultValue.
|
||||
/// If defaultValue is not set, it will default to the default initilization of the
|
||||
/// If defaultValue is not set, it will default to the default initialization of the
|
||||
/// corresponding type; bool: false, int: 0, ... as if one had used defaultValue=bool{}
|
||||
/// or defaultValue=int{}
|
||||
// General template, mark delete as it's not implemented, and should not be used!
|
||||
|
||||
@@ -76,7 +76,7 @@ UnitsSchema::translate(const Quantity& quant, double& factor, std::string& unitS
|
||||
auto unitSpecs = spec.translationSpecs.at(unitName);
|
||||
const auto unitSpec = std::find_if(unitSpecs.begin(), unitSpecs.end(), isSuitable);
|
||||
if (unitSpec == unitSpecs.end()) {
|
||||
throw RuntimeError("Suitable threshhold not found. Schema: " + spec.name
|
||||
throw RuntimeError("Suitable threshold not found. Schema: " + spec.name
|
||||
+ " value: " + std::to_string(value));
|
||||
}
|
||||
|
||||
|
||||
@@ -103,8 +103,8 @@ public:
|
||||
// static UnlimitedUnsigned operator+(UnlimitedUnsigned&& left, const UnlimitedUnsigned&
|
||||
// right); static UnlimitedUnsigned operator+(const UnlimitedUnsigned& left,
|
||||
// UnlimitedUnsigned&& right); static UnlimitedUnsigned operator+(UnlimitedUnsigned&& left,
|
||||
// UnlimitedUnsigned&& right); which would re-use left.parts or right.parts after possibly
|
||||
// growing it. The last one would use the larger of the two buffers
|
||||
// UnlimitedUnsigned&& right); which would reuse left.parts or right.parts after possibly
|
||||
// growing it. The last one would use the larger of the two buffers.
|
||||
UnlimitedUnsigned operator+(const UnlimitedUnsigned& right) const
|
||||
{
|
||||
size_t resultSize = std::max(parts.size(), right.parts.size());
|
||||
|
||||
@@ -172,7 +172,7 @@ inline XStr::~XStr()
|
||||
}
|
||||
|
||||
// Uses the compiler to create a cache of transcoded string literals so that each subsequent call
|
||||
// can re-use the data from the lambda's initial creation. Permits the same usage as
|
||||
// can reuse the data from the lambda's initial creation. Permits the same usage as
|
||||
// XStr("literal").unicodeForm()
|
||||
#define XStrLiteral(literal) \
|
||||
([]() -> const XStr& { \
|
||||
@@ -217,7 +217,7 @@ inline XUTF8Str::XUTF8Str(const char* const fromTranscode)
|
||||
inline XUTF8Str::~XUTF8Str() = default;
|
||||
|
||||
// Uses the compiler to create a cache of transcoded string literals so that each subsequent call
|
||||
// can re-use the data from the lambda's initial creation. Permits the same usage as
|
||||
// can reuse the data from the lambda's initial creation. Permits the same usage as
|
||||
// XStr("literal").unicodeForm()
|
||||
#define XUTF8StrLiteral(literal) \
|
||||
([]() -> const XUTF8Str& { \
|
||||
|
||||
@@ -1289,7 +1289,7 @@ class _Stairs(ArchComponent.Component):
|
||||
|
||||
if structure == "Massive":
|
||||
if structureThickness:
|
||||
# TODO Why 're-use' vBase?
|
||||
# TODO Why 'reuse' vBase?
|
||||
# '# Massive Structure to respect 'align' attribute'
|
||||
vBase = vBasedAligned.add(vRiserThickness)
|
||||
|
||||
|
||||
@@ -180,7 +180,7 @@ class ObjectTapping(PathCircularHoleBase.ObjectOp):
|
||||
holes = PathUtils.sort_locations(holes, ["x", "y"])
|
||||
|
||||
# This section is technical debt. The computation of the
|
||||
# target shapes should be factored out for re-use.
|
||||
# target shapes should be factored out for reuse.
|
||||
# This will likely mean refactoring upstream CircularHoleBase to pass
|
||||
# spot shapes instead of holes.
|
||||
|
||||
|
||||
@@ -544,7 +544,7 @@ class Snapmaker(Path.Post.Processor.PostProcessor):
|
||||
self.values["MOD_KITS_INSTALLED"] = []
|
||||
if args.boundaries: # may override machine boundaries, which is expected
|
||||
self.values["BOUNDARIES"] = args.boundaries
|
||||
self.values["MACHINE_NAME"] += " Boundaries overide=" + str(args.boundaries)
|
||||
self.values["MACHINE_NAME"] += " Boundaries override=" + str(args.boundaries)
|
||||
else:
|
||||
compatible_modkit_combos = [
|
||||
bt["mods"]
|
||||
|
||||
@@ -350,7 +350,7 @@ private:
|
||||
throw Py::Exception();
|
||||
}
|
||||
|
||||
// if non is returned the VTK object was created by annother VTK library, and the
|
||||
// if none is returned the VTK object was created by another VTK library, and the
|
||||
// python api used to create it cannot be used with FreeCAD
|
||||
vtkObjectBase* obj = vtkPythonUtil::GetPointerFromObject(pcObj, "vtkObject");
|
||||
if (!obj) {
|
||||
|
||||
@@ -88,7 +88,7 @@ FemPostFilter::FilterPipeline& FemPostFilter::getFilterPipeline(std::string name
|
||||
void FemPostFilter::setActiveFilterPipeline(std::string name)
|
||||
{
|
||||
if (m_pipelines.count(name) == 0) {
|
||||
throw Base::ValueError("Not a filter pipline name");
|
||||
throw Base::ValueError("Not a filter pipeline name");
|
||||
}
|
||||
|
||||
if (m_activePipeline != name && isValid()) {
|
||||
|
||||
@@ -380,7 +380,7 @@ class CommandManager:
|
||||
# like add_obj_on_gui_selobj_noset_edit but the selection is kept
|
||||
# and the selobj is expanded in the tree to see the added obj
|
||||
|
||||
# check if we should use python fitler
|
||||
# check if we should use python filter
|
||||
if vtk_compatibility_abort(True):
|
||||
return
|
||||
|
||||
|
||||
@@ -108,7 +108,7 @@ def _find_compatible_module():
|
||||
# use a single folder as path and try to load vtk
|
||||
sys.path = [folder]
|
||||
if vtk_module_compatible():
|
||||
# we do still unload, to let the user descide if he wants to use it
|
||||
# we do still unload, to let the user decide if they want to use it
|
||||
_unload_vtk_modules()
|
||||
sys.path = path
|
||||
return folder
|
||||
|
||||
@@ -346,7 +346,7 @@ void DrawComplexSection::makeAlignedPieces(const TopoDS_Shape& rawShape)
|
||||
uRotateAxis.Normalize();
|
||||
|
||||
|
||||
// the reversers control left to right vs right to left (or top to bottom vs botttom to top)
|
||||
// the reversers control left to right vs right to left (or top to bottom vs bottom to top)
|
||||
// arrangement of the cut pieces.
|
||||
double horizReverser{1.0};
|
||||
double verticalReverser{1.0};
|
||||
|
||||
Reference in New Issue
Block a user