mirror of
https://github.com/llvm/llvm-project.git
synced 2025-05-10 23:46:05 +00:00

Summary: Some of the mi commands implemented in lldb-mi are incomplete/not confirming to the spec. - `gdb-show` and `gdb-set` doesn't support getting/setting `disassembly-flavor` - `environment-cd` should also change the working directory for inferior - debugger CLI output should be printed as console-stream-output record, rather than being dumped directly to stdout - `target-select` should provide inner error message in mi response Related bug report: - https://llvm.org/bugs/show_bug.cgi?id=28026 - https://llvm.org/bugs/show_bug.cgi?id=28718 - https://llvm.org/bugs/show_bug.cgi?id=30265 Reviewers: ki.stfu, abidh Subscribers: abidh, ki.stfu, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D24711 llvm-svn: 291104
34 lines
734 B
C++
34 lines
734 B
C++
//===-- main.cpp ------------------------------------------------*- C++ -*-===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#include <cstdio>
|
|
|
|
#ifdef _WIN32
|
|
#include <direct.h>
|
|
#define getcwd _getcwd // suppress "deprecation" warning
|
|
#else
|
|
#include <unistd.h>
|
|
#endif
|
|
|
|
int
|
|
main(int argc, char const *argv[])
|
|
{
|
|
int a = 10;
|
|
|
|
char buf[512];
|
|
char *ans = getcwd(buf, sizeof(buf));
|
|
if (ans) {
|
|
printf("cwd: %s\n", ans);
|
|
}
|
|
|
|
printf("argc=%d\n", argc); // BP_printf
|
|
|
|
return 0;
|
|
}
|