warnings

Got Warning : this linearlayout layout or its framelayout parent is possibly useless

廉价感情. 提交于 2020-01-04 13:28:10
问题 <TabHost android:id="@+id/tabHost" android:layout_width="fill_parent" android:layout_height="fill_parent" > <LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > <FrameLayout android:id="@android:id/tabcontent" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1" > // --------------------------- Here I got warning ------------------------- <LinearLayout android:id="@+id/chat_list"

Got Warning : this linearlayout layout or its framelayout parent is possibly useless

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-04 13:26:30
问题 <TabHost android:id="@+id/tabHost" android:layout_width="fill_parent" android:layout_height="fill_parent" > <LinearLayout android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" > <FrameLayout android:id="@android:id/tabcontent" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1" > // --------------------------- Here I got warning ------------------------- <LinearLayout android:id="@+id/chat_list"

Any way to silence the UIDevice setOrientation warning?

笑着哭i 提交于 2020-01-04 08:05:11
问题 Anyone have a simple way to silence the undocumented UIDevice setOrientation warning? I found this piece of code that silences the undocumented UIPickerView setSoundsEnabled warning. 回答1: just declare the method in a category in the .h or .m file of wherever you use it: @interface UIDevice (MyPrivateNameThatAppleWouldNeverUseGoesHere) - (void) setOrientation:(UIInterfaceOrientation)orientation; @end 回答2: Why not just subscribe to the orientation notifications? They are supported and work at

warning: left-hand operand of comma expression has no effect

佐手、 提交于 2020-01-04 05:29:13
问题 i see this warning How to do fix it? Temp += (Table[i, temp3] - (MSB[i] ^ 0x1)); warning: left-hand operand of comma expression has no effect 回答1: what is Table object? If it is 2-dimensional array then you should write Table[i][temp3] In your code [i, temp3] is a comma operator - it evaluates the 1st parameter (i), ignores it and returns temp3, so you can just drop i if Table is some kind of container that accepts single-index to access its objects 回答2: Wrong syntax - if Table is a two

Should a diagnostic be emmited for discarded value expressions that do not have side effects?

六眼飞鱼酱① 提交于 2020-01-04 05:23:24
问题 After quite some debugging time I felt silly to discover a goof in my code that boils down to something like this : int main() { double p1[] = { 1, 2, 3 }; double p2[] = { 1, 2, 3 }; int color = 1; bool some_condition = true; if (some_condition) (p1, p2, color); } The (p1, p2, color) expression evaluates to its last operant, but should the compiler protect me in some way ? (Visual Studio told nothing) And yes you guessed it right, I wanted to call a draw function : Draw(p1, p2, color) 回答1: In

Getting GCC linker to warn about multiple function definitions

浪尽此生 提交于 2020-01-04 04:30:11
问题 Consider my small example C library: #include <external_library.h> void some_function(void) { external_library_call(); // Do other stuff... } It plans to make some_function() publicly callable. The library doesn't work, though, because the external library it requires also happens to use a function called some_function(), which happens to have the same prototype. GCC's linker doesn't care how many sources of the some_function symbol there are, though. It picks one seemingly at random and the

Webpack warning: You may need an appropriate loader to handle this file type (date-nfs)

为君一笑 提交于 2020-01-03 20:05:40
问题 I have a problem with my application. I have a website. I use date-fns to show a formatted date based on the user language. It works great, but I have updated date-fns and since then I have a warning. In my JavaScript code I use: const locale = require(`date-fns/locale/${props.match.params.lang}`) And with this, I can generate the right format like this: format(new Date(), 'D MMMM YYYY', { locale }) It works, but I dislike this warning I get when webpack is building. Can you help me to

Webpack warning: You may need an appropriate loader to handle this file type (date-nfs)

情到浓时终转凉″ 提交于 2020-01-03 20:04:18
问题 I have a problem with my application. I have a website. I use date-fns to show a formatted date based on the user language. It works great, but I have updated date-fns and since then I have a warning. In my JavaScript code I use: const locale = require(`date-fns/locale/${props.match.params.lang}`) And with this, I can generate the right format like this: format(new Date(), 'D MMMM YYYY', { locale }) It works, but I dislike this warning I get when webpack is building. Can you help me to

I have got this warning: com.sun.org.apache.xml.internal.serialize.OutputFormat is Sun proprietary API and may be removed in a future release

ぐ巨炮叔叔 提交于 2020-01-03 16:43:35
问题 My code is OutputFormat wOf = new OutputFormat( "XML", "ISO-8859-1", true ); help me to solve this warning.... thanks in advance 回答1: One solution is to not use that class. Another solution is to ignore the warning. Looking at the class, I suspect that this is the only viable solution ... if you stick with the Sun XML stack. (FWIW - this looks like a mistake on Sun's part in integrating the Apache XML stack into Java SE. The class should be in a different package that doesn't trigger this

FutureWarning with distplot in seaborn [duplicate]

家住魔仙堡 提交于 2020-01-03 13:37:08
问题 This question already has answers here : FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated use `arr[tuple(seq)]` (4 answers) Closed 11 months ago . I have this warning that shows up whenever I try to use distplot from seaborn , and I can't seem to figure out what I'm doing wrong, sorry if it's simple. Warning: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)] instead of arr[seq] . In the future this