Questions tagged [language-interoperability]

Language Interoperability is the ability of code to interact with code that is written using a different programming language. Language Interoperability can help maximize code reuse and, therefore, improve the efficiency of the development process.

176 questions
6
votes
2 answers

Calling Java from Clojure

When I try to run the following code (from the REPL) in Clojure: (dotimes [i 5] (.start (Thread. (fn [] (Thread/sleep (rand 1000)) (println (format "Finished %d on %s" i (Thread/currentThread))))))) I get the following…
Paul Reiners
  • 8,896
  • 30
  • 107
  • 178
6
votes
1 answer

Use Python alongside C# in Windows UWP app

I started writing an application in Python, but I now want to switch to C# and UWP. I know that you cannot write a UWP app in Python, but I am trying to see if I can write some code in Python and access that code from C#. For example, writing a…
M3579
  • 850
  • 2
  • 10
  • 21
6
votes
2 answers

How can I make my Objective-C class conform to Swift's `Equatable` protocol?

I have an Objective-C class (that happens to be a button, but that is not important), and at another part of my (mixed language) project, I have an array of these buttons and I'd like to get the index of a button using the find() method. Like…
Yerk
  • 948
  • 7
  • 19
6
votes
1 answer

Implementing unsafe Java interfaces

I've ran into a problem recently while developing with Spring Security. It has an interface GrantedAuthority with following signature: public interface GrantedAuthority extends Serializable, Comparable And as for Java 1.5 and later, the interface…
BorisOkunskiy
  • 1,752
  • 1
  • 16
  • 24
5
votes
8 answers

Is CORBA a language?

As i know CORBA is used to maintain interoperability in distributed systems by acting in middle. What i want to know is, is CORBA a language which has its own syntax of coding or do we code in CORBA using other languages like C#, Java etc. I went…
Nipuna
  • 5,638
  • 8
  • 55
  • 84
5
votes
5 answers

How can I pass data from Perl to Java?

I'm working on some Java <-> Perl interaction. I would like to know what the best way is to pass information from Perl to Java. (Great answers about Perl and Java here and here btw). There's a lot of text and XML(XML::Twig) I'm parsing in Perl, in a…
Fernando Briano
  • 7,579
  • 13
  • 55
  • 74
5
votes
2 answers

About using F# to create a Matrix assembly usable from C#

There are no builtin matrix functions in C#, but there are in the F# powerpack. Rather than using a third party or open source C# library, I wonder about rolling my own in F#, and exposing the useful bits to C#. Wondered if anybody has already…
Benjol
  • 57,639
  • 51
  • 180
  • 252
5
votes
1 answer

GNU Fortran and C interoperability

I have a large, mixed C/Fortran, code base, currently compiled using the Intel tools on Windows. I've been asked to port it to the GNU tools, on Linux. More or less at random, I've selected version 4.8. Where a C function is called from Fortran,…
Tom
  • 5,876
  • 1
  • 31
  • 52
5
votes
1 answer

Calling a Go callback function from C++ through SWIG

I'm trying to call the C++ function: void TestFunc(void(*f)(void)) { f(); } From Go Code. I would really want it to be that I just pass a Go function to that function. I know that I can wrap it into a class, and solve it using %feature("director"),…
user1921312
  • 101
  • 5
5
votes
2 answers

haskell scala interoperability

I am a Scala beginner and coming from Object Oriented Paradigm. While understanding Functional programming part of Scala, I was directed to Haskell - the pure Functional programming language. Exploring SO question-answers, I found that Java -…
Optimight
  • 2,809
  • 3
  • 25
  • 42
4
votes
1 answer

dart/flutter: getting data array from C/C++ using ffi?

The official flutter tutorial on C/C++ interop through ffi only touches on calling a C++ function and getting a single return value. Goal What if I have a data buffer created on C/C++ side, but want to deliver to dart/flutter-side to…
kakyo
  • 7,592
  • 9
  • 54
  • 95
4
votes
2 answers

D and C++ currently interoperability status

I'd like to learn D, but I haven't understood well an important thing. How's the current interoperability status between C++ and D? I'm sure it's impossible to link to C++ compiled binaries, as it doesn't even work with C++ compilers. But what if…
4
votes
1 answer

Objective C & Swift Interoperability causes error "Extensions may not contain stored properties"

I was working on one of my previous app that was done on Objective C. I need to add a new module to it and I decided to use Swift for that particular module. I have a class called HomePage in Objective C, I wanted to add some new IBActions and…
Midhun MP
  • 90,682
  • 30
  • 147
  • 191
4
votes
3 answers

can i use bdb(berkeley db) file created by c implementation (python bsddb) by oracle berkeley db java edition?

I have a berkeley db file (*.bdb) which is created by the C implementation(python bsddb module). Is it possible to read this file by a pure java implementation of Berkeley Db? I tried to read it using berkeley db java edition (je) but could not. je…
NeoAnderson
  • 377
  • 2
  • 4
  • 11
4
votes
1 answer

problems when accessing C union field

I'd like to access the field of C union in Go. below is my source code, but i got an error when compile it: package main // #include // #include // union bar { // char c; // int i; // double d; //…
Tony Bai
  • 151
  • 2
  • 6
1 2
3
11 12