Advertisement
pmcgee

C++Builder Community Ed Test - Calling Delphi source file

Jan 6th, 2020 (edited)
308
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.80 KB | None | 0 0
  1. //--------------------------
  2. // File1.cpp
  3. //--------------------------
  4. #pragma hdrstop
  5. #pragma argsused
  6.  
  7. #include <iostream>
  8. #include <testdelphi.hpp>
  9.  
  10. int _main()
  11. {
  12.     std::cout << "\n" << "C++ here. \n\n";
  13.     output();
  14.     std::cout << "C++ here. \n\n";
  15.     getchar();
  16.     return 0;
  17. }
  18.  
  19. //--------------------------
  20. // testdelphi.pas
  21. //--------------------------
  22. unit testdelphi;
  23. interface
  24.     procedure output;
  25. implementation
  26.     procedure output;
  27.     begin
  28.       writeln('Delphi');  writeln;
  29.     end;
  30. end.
  31.  
  32. //--------------------------
  33. // testdelphi.hpp
  34. //--------------------------
  35.  
  36. // CodeGear C++Builder
  37. // Copyright (c) 1995, 2018 by Embarcadero Technologies, Inc.
  38. // All rights reserved
  39.  
  40. // (DO NOT EDIT: machine generated header) 'testdelphi.pas' rev: 33.00 (Windows)
  41.  
  42. #ifndef TestdelphiHPP
  43. #define TestdelphiHPP
  44.  
  45. #pragma delphiheader begin
  46. #pragma option push
  47. #pragma option -w-      // All warnings off
  48. #pragma option -Vx      // Zero-length empty class member
  49. #pragma pack(push,8)
  50.  
  51. #include <System.hpp>
  52. #include <SysInit.hpp>
  53.  
  54. //-- user supplied -----------------------------------------------------------
  55. namespace Testdelphi
  56. {
  57. //-- forward type declarations -----------------------------------------------
  58. //-- type declarations -------------------------------------------------------
  59. //-- var, const, procedure ---------------------------------------------------
  60. extern DELPHI_PACKAGE void __fastcall output();
  61. }   /* namespace Testdelphi */
  62.  
  63. #if !defined(DELPHIHEADER_NO_IMPLICIT_NAMESPACE_USE) && !defined(NO_USING_NAMESPACE_TESTDELPHI)
  64. using namespace Testdelphi;
  65. #endif
  66. #pragma pack(pop)
  67. #pragma option pop
  68.  
  69. #pragma delphiheader end.
  70. //-- end unit ----------------------------------------------------------------
  71. #endif  // TestdelphiHPP
  72.  
  73. //--------------------------
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement