testclass_new
--
Ulink
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list
Hi Jonas,
This is in no way ideal, but I just wanted to tell you that it's possible.
Yeah, its a little bit hacky, but it works and so its ok for me ;-)
MANY thanks!
Maybe one of the vala guys will fix it in a later valac release (I
really think this is a bug).
--
Bernhard
Hi Evan,
In practice this really isn't an issue. Beyond the fact that I don't
think non-instance variables are widely used (I certainly don't use
many), they should be within your namespace anyways.
I agree, but the basic problem is that even private declared variables
are put into the .so as
Hackers' Guide to Vala (http://rodney.id.au/dev/vala/hackers.html) says:
Classes can be split across files, and this is often done for classes
with a lot of methods, or very long methods.
Seems I'm too dumb to make it, what is the syntax?
--
Bernhard
Consider the following (dummy) functions which shows memory leaks here
(valac 0.20.1 on ubuntu saucy 64Bit). It seems the problem exists with
Gee.ArrayList too. May someone confirm this?
//memory leak if len120 (nfill ist NOT the problem)
//NO memory leak if len=120
void Dummy1(int len)
{
Am 06.03.2014 01:07, schrieb Nor Jaidi Tuah:
Most probably it's the optimizing behaviour
of the memory allocator and has got nothing
to do with the vala compiler.
I don't think this is the case.
If you call Dummy2(20), after returning from this function there are
approximately 60MB of RAM
Am 05.03.2014 23:01, schrieb Steven Oliver:
What version libgee are you using?
The one installed with Ubuntu saucy (13.10): 0.8.2 (dpkg says)
Anyway, valac which saucy uses is not that old (0.20.1) and my Dummy()
functions shows the memory leak with standard vala arrays (no gee
involved here I
Hi Juerg,
According to valgrind 3.9.0, there are no leaks with this test code on
my system (up-to-date Linux on x86-64). I've tested with valac 0.20.1
and valac 0.22.1.
Confirmed, valgrind shows no memory leak. I'm puzzled.
void Dummy1(int len)
{
const int LOOPS=100;
string[] dummy =
Anyone who can give a hint why test 1 eats up memory and test 2 do not?
I was not able to find a explanation for this behaviour for myself.
--
Bernhard
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list
Are you sure it's not because optimizations?
No I'm not sure :-)
I simply don't understand the behaviour differences between test 1 and
test 2. But I'm curious to understand what's the reason for this.
Try to put Dummy1 method in external compile unit(i.e. different .vala and .c
file) and
You have to provide more details. What's your method of testing whether
memory used by Dummy1 has been freed or not? RSS is at 110 MB here
during the loop in either case.
I looked at RSS as you did.
glibc does not and cannot immediately return every freed block back to
the system. Some
'g_free' _is_ (normally) just a wrapper for 'free'. Please note that I'm
talking about glibc, not GLib.
There is also a memory allocator in GLib, GSlice, which can have its own
share of internal fragmentation. However, that's not used for plain
strings and arrays.
Ok, but the fact that
Hi,
valadoc.org seems online again, but if one type something into the
search field, it shows:
'Query failed: (0)s'
Is someone able to fix this?
--
Bernhard
___
vala-list mailing list
vala-list@gnome.org
Hi Jonathan,
many thanks for your hints!
--
Bernhard
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list
Hi,
don't know where to send vapi bug reports, so I send it to this mailing
list, please don't punish me :-)
Although xcb.vapi is deprecated and these are minor bugs, it should be
corrected I think:
Bug #1: xcb_format_t : replace [Simple] by [SimpleType]
Bug #2: xcb_visualtype_t: remove
Am 2016-07-21 um 21:52 schrieb Adam Tauno Williams:
> That is my greatest fear in picking up Vala.
My fears are not that big because of the nature of the "binding": VAPI.
Im using Vala now for two years for several projects and did not
encountered any real LANGUAGE bugs.
And creating or fixing
Am 2016-07-21 um 23:56 schrieb Dev_NIX:
> One question: is there a "standard" Vala library/classes?
Of course: GLib (and others), simply look at
http://www.valadoc.org/#!wiki=index
--
Bernhard
___
vala-list mailing list
vala-list@gnome.org
Am 2016-07-22 um 11:07 schrieb mar...@saepia.net:
> I think Vala needs a bit of "marketing" (quotes intentional).
Yeah, I agree ultimately! Without quotes!
Exaggerated: Vala is used widely, but no one knows about.
For example, some month ago, I took a look at the gnome-calculator C
source.
And
As Guillaume wrote, you have to use string? str and check string==null
FIRST.
But I think str.length==0 and str=="" are no high performance solutions,
especially for big/long strings.
Maybe this is better?
bool is_null_or_empty (string? str)
{
return str == null || str[0] == '\0';
}
Am 2017-01-17 um 12:09 schrieb rastersoft:
> That's true for the first one, but the second is as fast as str[0] == 0,
> because as soon as one byte doesn't fit, the function ends.
You are right, because str=="" indeed calls g_strcmp0(), but
str[0]=='\0' calls string_get() which seems not faster
Hi,
and last but not least one may overwrite the to_string method to get own
strings like this:
enum Test {
ONE,
TWO;
public string to_string() {
switch(this) {
case ONE:
return "enum number one";
case TWO:
return "enum number two";
default:
Am 2016-09-13 um 02:10 schrieb Michael Gratton:
> It really sounds like Vala needs some maintainers.
I think there are some Vala USERS out there, which are able and willing
to help with some minor and/or simple tasks and don't know how. So the
"heavy weights" like Jürg, Luca, Evan and the like
Am 2017-04-03 um 02:16 schrieb Nor Jaidi Tuah:
> It looks like Vala is going to have
> a parallel life:
>
> https://blogs.gnome.org/chergert/2017/03/31/rustic-gnome-day-3/
>
> I hope the gnome+rust people succeed in
> recreating the Vala awesomeness in Rust
> (even if they don't name it after
Hi Christian,
> Some of us in GNOME have spent many years writing programming languages
> and runtimes. Therefore our view is somewhat nuanced and opinionated.
As mine is ;-)
But I don't understand why the Gnome guys effectively ditch vala (as it
appears to me, maybe I'm wrong?). I simply can't
>> they have been part of a 200K lines of code project. They must have thought
>> it was
>> production ready.
We are SURE that it was and it IS production ready. We started the
project approx. 2-3 years ago (vala 0.22 on Ubuntu 14.04 I think) and it
is constantly growing while implementing new
Damit, too late ;-)
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list
Hi Sascha,
> doctype = cboDocType.get_active_text;
You are assigning a function (a delegate, means a pointer to a function)
to an string, thats not possible, use
doctype = cboDocType.get_active_text();
instead (parantheses on right side) to CALL the get_active_text()
function, which returns
Note 1: If get_active_text is a PROPERTY instead of a FUNCTION, your
code would have been ok.
Note 2: Much often, getter/setter functions also have a corresponding
property doing the same job. Use whatever you like.
___
vala-list mailing list
> To work with signals i like to use *.clicked.connect. So i tried
> box_pack_start (Gtk.Button revision = new Gtk.Button.with_label ("Add
> new Revision"));
> It looks like this isn't possible. What can i do?
Move revision outside from the box_pack_start() to access it from
outside, e.g. (not
> thing = thing ? create ();
I think you meant
thing = thing ?? create ();
Edward seems lazy and don't want to write "thing" two times ;-)
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list
Am 2017-05-07 um 12:17 schrieb Dr. Michael Lauer:
> I was pretty disappointed with the removal of the Posix profile,
> since there is quite some potential usage in embedded, kernel-space, and
> firmware niches.
ME, TOO! ;-)
Im actually using Vala for embedded purposes too (actually a Cortex
Hi Hans,
try
https://wiki.gnome.org/Projects/Vala/GIONetworkingSample
or basically
https://wiki.gnome.org/Projects/Vala/Documentation (below "Sample Code")
and of course Valadoc
https://valadoc.org/gio-2.0/GLib.SocketClient.html
https://valadoc.org/gio-2.0/GLib.SocketService.html
Hi Ralf,
> $ valac --pkg Gee-0.8 list.vala
use "valac --pkg gee-0.8 list.vala" (case sensitive).
Additionally, install Gee for ubuntu this way:
sudo apt install libgee-0.8-dev
___
vala-list mailing list
vala-list@gnome.org
> Does 'internal' hook into the Vala package system, meaning internal
> members cannot be accessed from a different package ?
See Vala tutorial (https://wiki.gnome.org/Projects/Vala/Tutorial):
internal: Access is limited exclusively to classes defined within the
same package
Cool stuff! You absolutely should add a link to the book at
https://en.wikipedia.org/wiki/Vala_(programming_language)
https://de.wikipedia.org/wiki/Vala_(Programmiersprache)
___
vala-list mailing list
vala-list@gnome.org
Hi,
> I don't understand why I can't sort my array... :-/ (glib.array)
seems this is a GLib.Array compare function binding (vapi) error or
something like this.
On C level, the compare objects are putted into your compare function as
pointers to pointers and not as pointers.
For a quick and
Hi Oliver,
I'm using a VERY thin (2-3 pages of code) self-written vala wrapper
which hides open/close and query (returning a 2 dimensional string array
as the result) using the Mysql and Sqlite Namespaces.
Then, I only send SQL queries and process the result. Of course I only
use basic SQL
Or try this:
First, install packages: sudo apt install tcc libgtk-vnc-2.0-dev
Second, try this VNC client script:
#!/usr/bin/vala --Xcc=-w --cc=tcc --pkg gtk+-3.0 --pkg gtk-vnc-2.0
int main (string[] args)
{
Gtk.init (ref args);
var window = new Gtk.Window ();
> valac -> compiler(ok)
> vala -> interpreter what/how/usage
As others said before, /usr/bin/vala is a command for using in Vala
scripts. It compiles the embedded script code on the fly to a temporary
binary and runs it afterwards.
Additionally, I'm using tcc (Ubuntu: sudo apt install tcc)
> You can use mono without recompile anything on other cpu's, including
> ARM/MIPS !!!
> I have a project for SetTopBoxes witch runs on Arm32/Mips32 with the same
> dll's (AnyCPU)
Of course, because it's managed (byte) code, something like java vm
code. Does it run on any OS (Windows,
> cellRendererText.text = ("%"+int64.FORMAT).printf((int64)obj); <<
> int64.FORMAT = "li"
>
> this works,
>
> but when i try this, witch is the same
> cellRendererText.text = ("%li").printf((int64)obj);
>
> i get thiss error
>
> application.vala:192.45-192.54: error: Argument 1: Cannot
> /home/wolfgang/Projekte/TestSqlite/application.vala:192:33: warning: format
> ‘%lld’ expects argument of type ‘long long int’, but argument 2 has type
> ‘gint64 {aka long int}’ [-Wformat=]
> But still the question is not answered ;-)
No warning with valac 0.30 (Ubuntu 16.04), so can't help
Hi,
> I used geany/geany-plugins from git, now debugger works fine ;-)
Perfect.
> So maybe last problem/question ;-)
NP, ask as much as you want. We need new Vala warriors ;-)
> "autocompletion" works with vala? If, i can't get it work
Primary, geany does autocompletion based on opened
Hi Wolfgang,
I'm using Geany and the "Debugger" and the "GeanyHighlightSelectedWord"
plugins.
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list
> I wanted to try porting a bigger C# project to vala (performance/etc.) but i
> think this is not a good idea.
Indeed, it is.
> As long as I have to deal with
> buildsystem/ctags/plugins/autocomplete/whatever and not with my actual
> work
> It just wastes my time.
But you have already
> I tried, but ubuntu has no debugger plugin ☹
sudo apt-get install geany geany-plugins geany-plugin-addons devhelp
Restart Geany and activate it via "Tools - Plugin Manager - Debugger".
For the "HighlightSelectedPlugin", which is very convenient, try this:
* Download
> THERE IS NO DEBUGGER -> Ubuntu 18.04
Calm down man, we will survive it ;-)
> Witch distri do you use?
Mine is Ubuntu 16.04.
Tried on 18.04 recently and unfortunately you are right: there is no
package geany-plugin-debugger :-(
Take a look at
> If a C# developer really (not only for fun) to change to Vala, then must
> necessarily be a valadevelop available!
> With completion and tooltips and and and.
Agreed, we need a good Vala IDE.
> I have already tried a few, but all do not meet the expectations
> (Geany/Anjuta/builder)
> The
Hi Daniel,
Im compiling Vala on Windows since years without any problems. Maybe the
following "receipe" will help:
Note: Use Win7 and above
Note: I'm using the 32 Bit MSYS2 version for some reason
Note: I'm using the same versions of Vala and Gee as on my Ubuntu 16.04
* Get MSYS2:
> I just tried autovala(Ubuntu 18.04), but getting an error. Witch packet
> is missing?
> /usr/include/readline/readline.h must exist to compile this project.
libreadline-dev ?
___
vala-list mailing list
vala-list@gnome.org
MANY thanks for this!
___
vala-list mailing list
vala-list@gnome.org
https://mail.gnome.org/mailman/listinfo/vala-list
51 matches
Mail list logo